Beispiel #1
0
$topic_perm = $gperm->get_viewtopic_perm_of_current_user($story['topicid'], $article->getVar('uid'));
$story = array_merge($story, $topic_perm);
$story['type'] = $article->getVar('type');
// Assign a number of comments
$ccount = $article->getVar('comments');
if ($ccount == 0) {
    $story['comentstotal'] = _MD_COMMENTS;
} elseif ($ccount == 1) {
    $story['comentstotal'] = _MD_ONECOMMENT;
} else {
    $story['comentstotal'] = sprintf(_MD_NUMCOMMENTS, $ccount);
}
//Assign the user information
$story['uid'] = $article->getVar('uid');
$story['uname'] = $article->getUname();
$story['realname'] = $article->getRealname();
$story['morelink'] = '';
$story['adminlink'] = 0;
if ($xoopsUser && $xoopsUser->isAdmin($xoopsModule->getVar('mid'))) {
    $story['adminlink'] = 1;
}
if ($article->showTopicimg()) {
    $story['topic_url'] = $article->imglink($bulletin_topicon_path);
    $story['align'] = $article->getTopicalign();
}
// Related article
if ($bulletin_use_relations) {
    $relations = $article->getRelated();
    foreach ($relations as $relation) {
        $relation_asign = array();
        $relation_asign['storyid'] = $relation->getVar('storyid');