<?php /* * Copyright (C) 2015 xiuno.com */ !defined('DEBUG') and exit('Access Denied.'); include './model/friendlink.func.php'; $order = param(1, $conf['order_default']); $order != 'tid' and $order = 'lastpid'; $fid = 0; // 主题列表 $toplist = thread_top_find_cache(); $threadlist = $order == 'tid' ? thread_new_find_cache() : thread_lastpid_find_cache(); $conf['order_default'] == $order and $threadlist = $toplist + $threadlist; // 去除无权限的主题 thread_list_access_filter($threadlist, $gid); // 友情链接,在线列表 $linklist = friendlink_find_cache(); $onlinelist = online_find_cache(); // SEO 相关 empty($setting) and $setting = array('sitebrief' => '', 'seo_title' => '', 'seo_keywords' => '', 'seo_description' => '', 'footer_code' => ''); $sitebrief = $setting['sitebrief']; $header['title'] = $setting['seo_title'] ? $setting['seo_title'] : $conf['sitename']; // 网站标题 $header['keywords'] = $setting['seo_keywords']; // 关键词 $header['description'] = $setting['seo_description']; // 描述 // 最新主题 //$new_tids = forum_new_tids(($order == 'lastpid' ? $threadlist : array())); include './mobile/view/index.htm';
<?php !defined('DEBUG') and exit('Access Denied.'); // 模板初始化依赖 $fid = param(1, 0); $page = param(2, 1); $order = param(3); !in_array($order, array('tid', 'lastpid', 'agrees')) and $order = $conf['order_default']; // 默认按照顶贴时间排序 $forum = forum_read($fid); empty($forum) and message(3, '板块不存在' . $fid); forum_access_user($fid, $gid, 'allowread') or message(-1, '您所在的用户组无权访问该板块。'); $pagesize = $conf['pagesize']; $pages = pages("forum-{$fid}-{page}-{$order}.htm", $forum['threads'], $page, $pagesize); $threadlist = thread_find_by_fid($fid, $page, $pagesize, $order); $onlinelist = online_find_cache($fid); $header['title'] = $forum['seo_title'] ? $forum['seo_title'] : $forum['name'] . '-' . $conf['sitename']; // 网站标题 $header['keywords'] = $forum['seo_keywords']; // 关键词 $header['navs'][] = "<a href=\"forum-{$fid}.htm\">{$forum['name']}</a>"; include './pc/view/forum.htm';