search_list.php 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. <?php
  2. Dever::setInput('ad_title', '搜索页');
  3. Dever::setInput('ad_name', 'search');
  4. $view
  5. ->set('name', 'search')
  6. ->set('title', 'content/lib/search.getInfo#name')
  7. ->import('inc/head')
  8. ->fetch('strong','content/lib/search.getInfo#name')
  9. ->loop
  10. (
  11. '.blogs_search li',
  12. 'content/lib/search.getAll',
  13. array
  14. (
  15. 'a|0' => array
  16. (
  17. 'href' => '$v.link',
  18. 'title' => '$v.info.name',
  19. 'target' => '',
  20. 'html' => '$v.info.name',
  21. ),
  22. 'p' => '$v.info.desc',
  23. 'a|1' => array
  24. (
  25. 'href' => '$v.cate_link',
  26. 'title' => '$v.cate_name',
  27. 'target' => '',
  28. 'html' => '$v.cate_name',
  29. ),
  30. '.color_green' => '<{$v.link}> - <{$v.cdate}>',
  31. )
  32. )
  33. ->fetch('.epages','<{Dever::page("current")}>')
  34. # 推荐
  35. ->loop
  36. (
  37. '.isgood_news li',
  38. 'main/api.push|key=home_tuijian&name=推荐阅读',
  39. array
  40. (
  41. 'a' => array
  42. (
  43. 'href' => '$v.link',
  44. 'title' => '$v.name',
  45. 'target' => '',
  46. 'img' => array
  47. (
  48. 'src' => '$v.pic',
  49. 'alt' => '$v.name',
  50. ),
  51. 'em' => array
  52. (
  53. 'html' => '<{$k+1}>',
  54. ),
  55. 'p' => array
  56. (
  57. 'html' => '$v.name',
  58. ),
  59. 'span' => array
  60. (
  61. 'class' => 'star5'
  62. )
  63. ),
  64. )
  65. )
  66. ->fetch('.isgood_news@style', 'main/api.push?key=home_tuijian&name=推荐阅读', 'none')
  67. ->fetch('.isgood_news .h_title', '推荐阅读')
  68. ->import('inc/foot')
  69. # display
  70. ->display();