Zeile 6 | Zeile 6 |
---|
* Website: http://mybb.com * License: http://mybb.com/about/license *
|
* Website: http://mybb.com * License: http://mybb.com/about/license *
|
* $Id: portal.php 5147 2010-07-30 23:18:16Z RyanGordon $
| * $Id: portal.php 5380 2011-02-21 12:04:43Z Tomm $
|
*/
define("IN_MYBB", 1);
| */
define("IN_MYBB", 1);
|
Zeile 380 | Zeile 380 |
---|
} $thread['subject'] = htmlspecialchars_uni($parser->parse_badwords($thread['subject'])); $thread['threadlink'] = get_thread_link($thread['tid']);
|
} $thread['subject'] = htmlspecialchars_uni($parser->parse_badwords($thread['subject'])); $thread['threadlink'] = get_thread_link($thread['tid']);
|
| $thread['lastpostlink'] = get_thread_link($thread['tid'], 0, "lastpost");
|
eval("\$threadlist .= \"".$templates->get("portal_latestthreads_thread")."\";"); $altbg = alt_trow(); }
| eval("\$threadlist .= \"".$templates->get("portal_latestthreads_thread")."\";"); $altbg = alt_trow(); }
|
Zeile 406 | Zeile 407 |
---|
while($forumrow = $db->fetch_array($query)) { $forum[$forumrow['fid']] = $forumrow;
|
while($forumrow = $db->fetch_array($query)) { $forum[$forumrow['fid']] = $forumrow;
|
| }
$numannouncements = intval($mybb->settings['portal_numannouncements']); if(!$numannouncements) { $numannouncements = 10; // Default back to 10
|
}
$pids = '';
| }
$pids = '';
|
Zeile 417 | Zeile 424 |
---|
LEFT JOIN ".TABLE_PREFIX."threads t ON (t.tid=p.tid) WHERE t.fid IN (".$announcementsfids.") AND t.visible='1' AND t.closed NOT LIKE 'moved|%' AND t.firstpost=p.pid ORDER BY t.dateline DESC
|
LEFT JOIN ".TABLE_PREFIX."threads t ON (t.tid=p.tid) WHERE t.fid IN (".$announcementsfids.") AND t.visible='1' AND t.closed NOT LIKE 'moved|%' AND t.firstpost=p.pid ORDER BY t.dateline DESC
|
LIMIT 0, ".$mybb->settings['portal_numannouncements']
| LIMIT 0, {$numannouncements}"
|
); while($getid = $db->fetch_array($query)) {
| ); while($getid = $db->fetch_array($query)) {
|
Zeile 436 | Zeile 443 |
---|
if(is_array($forum)) { foreach($forum as $fid => $forumrow)
|
if(is_array($forum)) { foreach($forum as $fid => $forumrow)
|
{
| {
|
$forumpermissions[$fid] = forum_permissions($fid); } }
| $forumpermissions[$fid] = forum_permissions($fid); } }
|
Zeile 450 | Zeile 457 |
---|
LEFT JOIN ".TABLE_PREFIX."users u ON (u.uid = t.uid) WHERE t.fid IN (".$announcementsfids.") AND t.tid IN (0{$tids}) AND t.visible='1' AND t.closed NOT LIKE 'moved|%' ORDER BY t.dateline DESC
|
LEFT JOIN ".TABLE_PREFIX."users u ON (u.uid = t.uid) WHERE t.fid IN (".$announcementsfids.") AND t.tid IN (0{$tids}) AND t.visible='1' AND t.closed NOT LIKE 'moved|%' ORDER BY t.dateline DESC
|
LIMIT 0, ".$mybb->settings['portal_numannouncements']
| LIMIT 0, {$numannouncements}"
|
); while($announcement = $db->fetch_array($query)) {
|
); while($announcement = $db->fetch_array($query)) {
|
| // Make sure we can view this announcement if($forumpermissions[$announcement['fid']]['canview'] == 0 || $forumpermissions[$announcement['fid']]['canviewthreads'] == 0 || $forumpermissions[$announcement['fid']]['canonlyviewownthreads'] == 1 && $announcement['uid'] != $mybb->user['uid']) { continue; }
|
$announcement['message'] = $posts[$announcement['tid']]['message']; $announcement['pid'] = $posts[$announcement['tid']]['pid']; $announcement['smilieoff'] = $posts[$announcement['tid']]['smilieoff'];
| $announcement['message'] = $posts[$announcement['tid']]['message']; $announcement['pid'] = $posts[$announcement['tid']]['pid']; $announcement['smilieoff'] = $posts[$announcement['tid']]['smilieoff'];
|