} if (empty($metakeywords)) { $metakeywords = $article['title']; } if (empty($metadescription)) { $metadescription = $article['summary'] ? $article['summary'] : $article['title']; } list($seccodecheck, $secqaacheck) = seccheck('publish'); $catid = $article['catid']; if (!$_G['setting']['relatedlinkstatus']) { $_G['relatedlinks'] = get_related_link('article'); } else { $content['content'] = parse_related_link($content['content'], 'article'); } if (isset($_G['makehtml'])) { helper_makehtml::portal_article($cat, $article, $page); } portal_get_per_next_article($article); $tpldirectory = ''; $articleprimaltplname = $cat['articleprimaltplname']; if (strpos($articleprimaltplname, ':') !== false) { list($tpldirectory, $articleprimaltplname) = explode(':', $articleprimaltplname); } include_once template("diy:portal/view:{$catid}", NULL, $tpldirectory, NULL, $articleprimaltplname); function parseforumattach(&$post, $aids) { global $_G; if ($aids = array_unique($aids)) { require_once libfile('function/attachment'); $finds = $replaces = array(); foreach (C::t('forum_attachment_n')->fetch_all_by_id('tid:' . $post['tid'], 'aid', $aids) as $attach) {