Beispiel #1
0
function forum_get_prefix($prefixId)
{
    global $set, $db, $apx, $user;
    static $prefixes;
    if (!isset($prefixes)) {
        $prefixes = forum_prefixes();
    }
    return $prefixes[$prefixId]['code'];
}
Beispiel #2
0
     }
 }
 //Anhänge auslesen
 $attachments = '';
 $data = $db->fetch("SELECT * FROM " . PRE . "_forum_attachments WHERE ( postid='" . $postinfo['postid'] . "' AND hash='" . addslashes($postinfo['hash']) . "' ) ORDER BY name ASC");
 if (count($data)) {
     require BASEDIR . 'lib/class.mediamanager.php';
     $mm = new mediamanager();
     foreach ($data as $res) {
         $ext = strtolower($mm->getext($res['name']));
         $attachments .= '<img src="' . $typeinfo[$ext][1] . '" alt="" style="vertical-align:middle;" /> ' . $res['name'] . ' (' . round($res['size'] / 1024) . ' KB)';
     }
 }
 //Präfixe
 $prefixdata = array();
 $prefixInfo = forum_prefixes($foruminfo['forumid']);
 foreach ($prefixInfo as $prefix) {
     $prefixdata[] = array('ID' => $prefix['prefixid'], 'TITLE' => compatible_hsc($prefix['title']), 'SELECTED' => $_POST['prefix'] == $prefix['prefixid']);
 }
 $apx->tmpl->assign('USERID', $postinfo['userid']);
 if ($postinfo['userid']) {
     $apx->tmpl->assign('USERNAME', replace($postinfo['username']));
 } else {
     $apx->tmpl->assign('USERNAME', compatible_hsc($_POST['username']));
 }
 $apx->tmpl->assign('TITLE', compatible_hsc($_POST['title']));
 $apx->tmpl->assign('PREFIX', $prefixdata);
 $apx->tmpl->assign('TEXT', compatible_hsc($_POST['text']));
 $apx->tmpl->assign('ICON', iif($_POST['icon'] === 'none', $_POST['icon'], (int) $_POST['icon']));
 $apx->tmpl->assign('ICONLIST', $icondata);
 $apx->tmpl->assign('SMILEYLIST', $smiledata);
Beispiel #3
0
    ++$i;
    //Nicht sichtbare Foren überspringen
    if (!forum_access_visible($res) || !forum_access_read($res)) {
        $jump = $res['level'];
        continue;
    }
    if ($jump && $res['level'] > $jump) {
        continue;
    } else {
        $jump = 0;
    }
    $forumdata[$i]['ID'] = $res['forumid'];
    $forumdata[$i]['TITLE'] = replace($res['title']);
    $forumdata[$i]['LEVEL'] = $res['level'];
    $forumdata[$i]['ISCAT'] = $res['iscat'];
    $prefixes = forum_prefixes($res['forumid']);
    if ($prefixes) {
        $prefixdata = array();
        foreach ($prefixes as $pre) {
            $prefixdata[] = array('ID' => $pre['prefixid'], 'TITLE' => replace($pre['title']));
        }
        $pforum[] = array('TITLE' => replace($res['title']), 'PREFIX' => $prefixdata);
    }
}
$apx->tmpl->assign('PFORUM', $pforum);
$apx->tmpl->assign('FORUM', $forumdata);
$apx->tmpl->parse('search');
////////////////////////////////////////////////////////////////////////////////////////////////////////
$apx->tmpl->assign('PATHEND', $apx->lang->get('HEADLINE_SEARCH'));
titlebar($apx->lang->get('HEADLINE_SEARCH'));
////////////////////////////////////////////////////////////////////////////////////////////////////////