SeoController.class.php 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. <?php
  2. namespace Admin\Controller;
  3. /**
  4. * seo设置
  5. * @author Devil
  6. * @blog http://gong.gg/
  7. * @version 0.0.1
  8. * @datetime 2016-12-01T21:51:08+0800
  9. */
  10. class SeoController extends CommonController
  11. {
  12. /**
  13. * [_initialize 前置操作-继承公共前置方法]
  14. * @author Devil
  15. * @blog http://gong.gg/
  16. * @version 0.0.1
  17. * @datetime 2016-12-03T12:39:08+0800
  18. */
  19. public function _initialize()
  20. {
  21. // 调用父类前置方法
  22. parent::_initialize();
  23. // 登录校验
  24. $this->Is_Login();
  25. // 权限校验
  26. $this->Is_Power();
  27. }
  28. /**
  29. * [Index 配置列表]
  30. * @author Devil
  31. * @blog http://gong.gg/
  32. * @version 0.0.1
  33. * @datetime 2016-12-06T21:31:53+0800
  34. */
  35. public function Index()
  36. {
  37. // url模式
  38. $this->assign('seo_url_model_list', L('seo_url_model_list'));
  39. // 文章标题seo方案
  40. $this->assign('seo_article_browser_list', L('seo_article_browser_list'));
  41. // 频道标题seo方案
  42. $this->assign('seo_channel_browser_list', L('seo_channel_browser_list'));
  43. // 配置信息
  44. $data = M('Config')->getField('only_tag,name,describe,value,error_tips');
  45. $this->assign('data', $data);
  46. $this->display('Index');
  47. }
  48. /**
  49. * [Save 配置数据保存]
  50. * @author Devil
  51. * @blog http://gong.gg/
  52. * @version 0.0.1
  53. * @datetime 2017-01-02T23:08:19+0800
  54. */
  55. public function Save()
  56. {
  57. $this->MyConfigSave();
  58. }
  59. }
  60. ?>