1
0
mirror of https://github.com/e107inc/e107.git synced 2025-07-22 23:41:20 +02:00

More notice removals, again.

This commit is contained in:
Tijn Kuyper
2012-12-08 20:22:05 +01:00
parent cbcf7581a4
commit 3793b27822
11 changed files with 35 additions and 35 deletions

View File

@@ -25,7 +25,7 @@ require_once (e_HANDLER."userclass_class.php");
require_once (e_HANDLER."ren_help.php");
require_once (e_HANDLER."comment_class.php");
if (!$FAQ_VIEW_TEMPLATE)
if (!vartrue($FAQ_VIEW_TEMPLATE))
{
if (file_exists(THEME."faqs_template.php"))
{

View File

@@ -1198,7 +1198,7 @@ class e107forum
$threadInfo['thread_id'] = intval($threadInfo['thread_id']);
$search = array('{THREAD_TITLE}', '{THREAD_HREF}');
$replace = array($threadInfo['thread_name'], $e107->url->create('forum/thread/view', $threadInfo)); // $thread->threadInfo - no reference found
$replace = array(vartrue($threadInfo['thread_name']), $e107->url->create('forum/thread/view', $threadInfo)); // $thread->threadInfo - no reference found
$FORUM_CRUMB['thread']['value'] = str_replace($search, $replace, $FORUM_CRUMB['thread']['value']);
$FORUM_CRUMB['fieldlist'] = 'sitename,forums,parent,subparent,forum,thread';

View File

@@ -83,7 +83,7 @@ define('MODERATOR', USER && $forum->isModerator(USERID));
require_once(e_HANDLER.'ren_help.php');
e107::getScBatch('view', 'forum');
e107::getScBatch('post', 'forum')->setScVar('forum', $forum)->setScVar('threadInfo', $threadInfo);
e107::getScBatch('post', 'forum')->setScVar('forum', $forum)->setScVar('threadInfo', vartrue($threadInfo));
$gen = new convert;
$fp = new floodprotect;
@@ -437,7 +437,7 @@ if (isset($_POST['update_reply']))
require_once(HEADERF);
if ($error)
if (vartrue($error))
{
$ns->tablerender(LAN_20, $error);
}
@@ -491,7 +491,7 @@ if ($action == 'edit' || $action == 'quote')
// -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
//Load forumpost template
if (!$FORUMPOST)
if (!vartrue($FORUMPOST))
{
if (is_readable(THEME.'forum_post_template.php'))
{

View File

@@ -64,7 +64,7 @@ if (!$forum->checkPerm($forumId, 'view'))
$forumInfo = $forum->forumGet($forumId);
$threadsViewed = $forum->threadGetUserViewed();
if (!$FORUM_VIEW_START)
if (!vartrue($FORUM_VIEW_START))
{
if (file_exists(THEME.'forum_viewforum_template.php'))
{
@@ -233,7 +233,7 @@ $reg_threads = 0;
$unstuck = false;
$threadList = $forum->forumGetThreads($forumId, $threadFrom, $view);
$subList = $forum->forumGetSubs($forum_id);
$subList = $forum->forumGetSubs(vartrue($forum_id));
$gen = new convert;
$fVars->SUBFORUMS = '';

View File

@@ -138,7 +138,7 @@ if (file_exists(THEME . 'forum_design.php'))
{
include_once (THEME . 'forum_design.php');
}
if (!$FORUMSTART)
if (!vartrue($FORUMSTART))
{
if (file_exists(THEME . 'forum_viewtopic_template.php'))
{
@@ -215,7 +215,7 @@ if ($forum->checkPerm($thread->threadInfo['thread_forum_id'], 'thread'))
$tVars->BUTTONS .= "<a href='" . $e107->url->create('forum/thread/new', array('id' => $thread->threadInfo['thread_forum_id'])) . "'>" . IMAGE_newthread . "</a>";
}
$tVars->POLL = $pollstr;
$tVars->POLL = vartrue($pollstr);
$tVars->FORUMJUMP = forumjump();
@@ -265,14 +265,14 @@ foreach ($postList as $postInfo)
{
$postInfo['thread_start'] = true;
e107::getScBatch('view', 'forum')->setScVar('postInfo', $postInfo);
$forthr = $e107->tp->parseTemplate($FORUMTHREADSTYLE, true, $forum_shortcodes) . "\n";
$forthr = $e107->tp->parseTemplate($FORUMTHREADSTYLE, true, vartrue($forum_shortcodes)) . "\n";
}
}
unset($loop_uid);
if ($forum->checkPerm($thread->threadInfo['thread_forum_id'], 'post') && $thread->threadInfo['thread_active'])
{
if (!$forum_quickreply)
if (!vartrue($forum_quickreply))
{
$tVars->QUICKREPLY = "
<form action='" . $e107->url->create('forum/thread/reply', array('id' => $thread->threadId)) . "' method='post'>
@@ -293,7 +293,7 @@ if ($forum->checkPerm($thread->threadInfo['thread_forum_id'], 'post') && $thread
$forend = $tp->simpleParse($FORUMEND, $tVars);
$forumstring = $forstr . $forthr . $forrep . $forend;
$forumstring = $forstr . $forthr . vartrue($forrep) . $forend;
//If last post came after USERLV and not yet marked as read, mark the thread id as read
$threadsViewed = explode(',', $currentUser['user_plugin_forum_viewed']);

View File

@@ -130,7 +130,7 @@ class plugin_forum_post_shortcodes extends e_shortcode
global $action, $threadInfo;
if (MODERATOR && $action == "nt")
{
$thread_sticky = (isset($_POST['threadtype']) ? $_POST['threadtype'] : $threadInfo['thread_sticky']); // no reference of 'head' $threadInfo['head']['thread_sticky']
$thread_sticky = (isset($_POST['threadtype']) ? $_POST['threadtype'] : vartrue($threadInfo['thread_sticky'])); // no reference of 'head' $threadInfo['head']['thread_sticky']
return "<br /><span class='defaulttext'>".LAN_400."<input name='threadtype' type='radio' value='0' ".(!$thread_sticky ? "checked='checked' " : "")." />".LAN_1."&nbsp;<input name='threadtype' type='radio' value='1' ".($thread_sticky == 1 ? "checked='checked' " : "")." />".LAN_2."&nbsp;<input name='threadtype' type='radio' value='2' ".($thread_sticky == 2 ? "checked='checked' " : "")." />".LAN_3."</span>";
}
return '';
@@ -147,7 +147,7 @@ class plugin_forum_post_shortcodes extends e_shortcode
function sc_noemotes()
{
if($eaction == true) { return ; }
if(vartrue($eaction) == true) { return ; }
return "<input type='checkbox' name='no_emote' value='1' />&nbsp;<span class='defaulttext'>".LAN_FORUMPOST_EMOTES.'</span>';
}
@@ -158,7 +158,7 @@ class plugin_forum_post_shortcodes extends e_shortcode
$pref = e107::getPlugPref('forum');
if($eaction == true) { return ; }
if ($pref['notify'] && $action == 'nt' && USER)
if (vartrue($pref['notify']) && $action == 'nt' && USER)
{
if(isset($_POST['fpreview']))
{

View File

@@ -16,28 +16,28 @@ if(!defined("USER_WIDTH")){ define("USER_WIDTH","width:95%"); }
// the user box and subject box are not always displayed, therefore we need to define them /in case/ they are, if not they'll be ignored.
if(!$userbox)
if(!vartrue($userbox))
{
$userbox = "<tr>
<td class='forumheader2' style='width:20%'>".LAN_61."</td>
<td class='forumheader2' style='width:80%'>
<input class='tbox' type='text' name='anonname' size='71' value='".$anonname."' maxlength='20' style='width:95%' />
<input class='tbox' type='text' name='anonname' size='71' value='".vartrue($anonname)."' maxlength='20' style='width:95%' />
</td>
</tr>";
}
if(!$subjectbox)
if(!vartrue($subjectbox))
{
$subjectbox = "<tr>
<td class='forumheader2' style='width:20%'>".LAN_62."</td>
<td class='forumheader2' style='width:80%'>
<input class='tbox' type='text' name='subject' size='71' value='".$subject."' maxlength='100' style='width:95%' />
<input class='tbox' type='text' name='subject' size='71' value='".vartrue($subject)."' maxlength='100' style='width:95%' />
</td>
</tr>";
}
// the poll is optional, be careful when changing the values here, only change if you know what you're doing ...
if(!$poll_form)
if(!vartrue($poll_form))
{
if(is_readable(e_PLUGIN.'poll/poll_class.php')) {
require_once(e_PLUGIN.'poll/poll_class.php');
@@ -47,7 +47,7 @@ if(!$poll_form)
}
// finally, file attach is optional, again only change this if you know what you're doing ...
if(!$fileattach)
if(!vartrue($fileattach))
{
$fileattach = "
<tr>
@@ -55,7 +55,7 @@ $fileattach = "
</tr>
<tr>
<td style='width:20%' class='forumheader3'>".LAN_392."</td>
<td style='width:80%' class='forumheader3'>".LAN_393." | ".$allowed_filetypes." |<br />".LAN_394."<br />".LAN_395.": ".($max_upload_size ? $max_upload_size.LAN_396 : ini_get('upload_max_filesize'))."
<td style='width:80%' class='forumheader3'>".LAN_393." | ".vartrue($allowed_filetypes)." |<br />".LAN_394."<br />".LAN_395.": ".(vartrue($max_upload_size) ? $max_upload_size.LAN_396 : ini_get('upload_max_filesize'))."
<br />
<div id='fiupsection'>
<span id='fiupopt'>
@@ -70,7 +70,7 @@ $fileattach = "
//</tr>
}
// If the upload directory is not writable, we need to alert the user about this.
if(!$fileattach_alert)
if(!vartrue($fileattach_alert))
{
$fileattach_alert = "
<tr>
@@ -126,7 +126,7 @@ $FORUMPOST = "
";
}
if(!$FORUMPOST_REPLY)
if(!vartrue($FORUMPOST_REPLY))
{
$FORUMPOST_REPLY = "
<div style='text-align:center'>
@@ -176,7 +176,7 @@ $FORUMPOST_REPLY = "
";
}
if(!$LATESTPOSTS_START)
if(!vartrue($LATESTPOSTS_START))
{
$LATESTPOSTS_START = "
<table style='".USER_WIDTH."' class='fborder'>
@@ -187,7 +187,7 @@ LAN_101."{LATESTPOSTSCOUNT}".LAN_102."
</tr>";
}
if(!$LATESTPOSTS_POST)
if(!vartrue($LATESTPOSTS_POST))
{
$LATESTPOSTS_POST = "
<tr>
@@ -200,14 +200,14 @@ $LATESTPOSTS_POST = "
";
}
if(!$LATESTPOSTS_END)
if(!vartrue($LATESTPOSTS_END))
{
$LATESTPOSTS_END = "
</table>
";
}
if(!$THREADTOPIC_REPLY)
if(!vartrue($THREADTOPIC_REPLY))
{
$THREADTOPIC_REPLY = "
<table style='".USER_WIDTH."' class='fborder'>

View File

@@ -1034,7 +1034,7 @@ class siteStats
if ($do_errors XOR !$found)
{
$totalArray[$k] = $v;
$total += $v['ttlv'];
$total += vartrue($v['ttlv']);
}
}
$totalArray = $this -> arraySort($totalArray, "ttl");

View File

@@ -79,7 +79,7 @@ if (count($newsFeed->feedList))
}
}
$text = $NEWSFEED_LIST_START . $data . $NEWSFEED_LIST_END;
$text = $NEWSFEED_LIST_START . vartrue($data) . $NEWSFEED_LIST_END;
$ns->tablerender(NFLAN_29, $text);
require_once(FOOTERF);

View File

@@ -504,9 +504,9 @@ class poll
<span class='smalltext'>".LAN_386."</span>
</td>
</tr>
<tr><td style='width:20%'><div class='normaltext'>".LAN_5."</div></td><td style='width:80%'class='forumheader3'><input class='tbox' type='text' name='poll_title' size='70' value='".$tp->post_toForm($_POST['poll_title'])."' maxlength='200' /></td></tr>";
<tr><td style='width:20%'><div class='normaltext'>".LAN_5."</div></td><td style='width:80%'class='forumheader3'><input class='tbox' type='text' name='poll_title' size='70' value='".$tp->post_toForm(vartrue($_POST['poll_title']))."' maxlength='200' /></td></tr>";
$option_count = (count($_POST['poll_option']) ? count($_POST['poll_option']) : 1);
$option_count = (count(vartrue($_POST['poll_option'])) ? count($_POST['poll_option']) : 1);
$text .= "<tr>
<td style='width:20%'>".LAN_391."</td>
<td style='width:80%'>
@@ -530,7 +530,7 @@ class poll
<tr>
<td style='width:20%'>".POLL_506."</td>
<td style='width:80%'>
<input type='radio' name='multipleChoice' value='1'".($_POST['multipleChoice'] ? " checked='checked'" : "")." /> ".POLL_507."&nbsp;&nbsp;
<input type='radio' name='multipleChoice' value='1'".(vartrue($_POST['multipleChoice']) ? " checked='checked'" : "")." /> ".POLL_507."&nbsp;&nbsp;
<input type='radio' name='multipleChoice' value='0'".(!$_POST['multipleChoice'] ? " checked='checked'" : "")." /> ".POLL_508."
</td>
</tr>
@@ -538,7 +538,7 @@ class poll
<tr>
<td style='width:30%'>".POLLAN_16."</td>
<td>
<input type='radio' name='storageMethod' value='0'".(!$_POST['storageMethod'] ? " checked='checked'" : "")." /> ".POLLAN_17."<br />
<input type='radio' name='storageMethod' value='0'".(!vartrue($_POST['storageMethod']) ? " checked='checked'" : "")." /> ".POLLAN_17."<br />
<input type='radio' name='storageMethod' value='1'".($_POST['storageMethod'] == 1 ? " checked='checked'" : "")." /> ".POLLAN_18."<br />
<input type='radio' name='storageMethod' value='2'".($_POST['storageMethod'] ==2 ? " checked='checked'" : "")." /> ".POLLAN_19."
</td></tr>

View File

@@ -110,7 +110,7 @@ else
}
}
}
if ($records > 30)
if (vartrue($records) > 30)
{
$records = 30;
}