IndexController.class.php 920 B

12345678910111213141516171819202122232425262728293031
  1. <?php
  2. namespace Home\Controller;
  3. use Think\Controller;
  4. class IndexController extends BaseController {
  5. public function index(){
  6. if(!file_exists('./Application/Common/Conf/config.php')){
  7. header("location:./install");
  8. exit();
  9. }
  10. $this->checkLogin(false);
  11. $login_user = session("login_user");
  12. $this->assign("login_user" ,$login_user);
  13. if (LANG_SET == 'en-us') {
  14. $demo_url = "https://www.showdoc.cc/demo-en";
  15. $help_url = "https://www.showdoc.cc/help-en";
  16. $creator_url = "https://github.com/star7th";
  17. }
  18. else{
  19. $demo_url = "https://www.showdoc.cc/demo";
  20. $help_url = "https://www.showdoc.cc/help";
  21. $creator_url = "https://blog.star7th.com/";
  22. }
  23. $this->assign("demo_url" ,$demo_url);
  24. $this->assign("help_url" ,$help_url);
  25. $this->assign("creator_url" ,$creator_url);
  26. $this->display();
  27. }
  28. }