article.php 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. /*
  3. |--------------------------------------------------------------------------
  4. | home
  5. |--------------------------------------------------------------------------
  6. */
  7. $view
  8. ->set('name', 'article')
  9. ->set('title', 'main/api.news_view#name')
  10. ->import('inc/head')
  11. # 定义名称
  12. ->fetch('body@t', '1')
  13. ->fetch('h1', 'main/api.news_view#name')
  14. ->fetch(array('.article-infos span', 0), 'main/api.news_view#cate_name')
  15. ->fetch(array('.article-infos span', 1), 'main/api.news_view#source_name')
  16. ->fetch(array('.article-infos span', 2), 'main/api.news_view#cdate')
  17. ->fetch('.article-content', 'main/api.news_view#content')
  18. //->fetch(array('.float-shares img@src', 0), 'main/api.config#wechat')
  19. ->fetch(array('.float-shares dl@style', 0), 'main/api.news_next#state')
  20. ->fetch(array('.float-shares a@href', 0), 'main/api.news_next#link')
  21. ->fetch(array('.float-shares dd', 0), 'main/api.news_next#name')
  22. ->fetch(array('.float-shares dl@style', 1), 'main/api.news_prev#state')
  23. ->fetch(array('.float-shares a@href', 1), 'main/api.news_prev#link')
  24. ->fetch(array('.float-shares dd', 1), 'main/api.news_prev#name')
  25. ->import('inc/foot')
  26. # display
  27. ->display();