Version: , by lwhite
Developer Last Online: Jul 2007
Version: Unknown
Rating:
Released: 03-11-2005
Last Update: Never
Installs: 0
No support by the author.
I am having trouble with Vb 3.0.7 with vbJournal and vbAdvanced installed. I am getting the follow Parse errors up show thread:
Quote:
Parse error: parse error, unexpected ':' in /home/slackers/public_html/forums/includes/functions_showthread.php(656) : eval()'d code on line 256
After Editing Postbit_legacy, I get:
Quote:
The following error occurred when attempting to evaluate this template:
Parse error: parse error, unexpected ':' in /home/slackers/public_html/forums/includes/adminfunctions_template.php(3096) : eval()'d code on line 256
This is likely caused by a malformed conditional statement. It is highly recommended that you fix this error before continuing, but you may continue as-is if you wish.
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="0" border="0" width="100%" align="center">
<tr>
<if condition="$show['announcement']">
<td class="thead" style="font-weight:normal" colspan="2">
<img class="inlineimg" src="$stylevar[imgdir_statusicon]/post_$post[statusicon].gif" alt="$post[statustitle]" border="0" />
<phrase 1="$post[startdate]" 2="$post[enddate]">$vbphrase[x_until_y]</phrase>
</td>
<else />
<td class="thead" style="font-weight:normal" $scrolltothis>
<!-- status icon and date -->
<a name="post$post[postid]"><img class="inlineimg" src="$stylevar[imgdir_statusicon]/post_$post[statusicon].gif" alt="$post[statustitle]" border="0" /></a>
$post[postdate]<if condition="!$show['detailedtime']">, $post[posttime]</if>
$post[firstnewinsert]
<!-- / status icon and date -->
</td>
<td class="thead" style="font-weight:normal" align="$stylevar[right]">
<!-- checks for warning system -->
<if condition="THIS_SCRIPT=='showthread' AND ($buttons=='Text' OR $buttons=='')">
<if condition="$hierarchical=='No'">
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND $post[usergroupid]!=5 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])">
<a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[username]</a> ?
</if>
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND $post[usergroupid]!=5 AND ($bbuserinfo[usergroupid]==7 OR $bbuserinfo[usergroupid]==5 OR $bbuserinfo[usergroupid]==6)">
<a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[username]'s Warnings</a> ?
</if>
<if condition="$post[userid]==$bbuserinfo[userid] AND $post[usergroupid]!=6 AND $post[usergroupid]!=7 AND $post[usergroupid]!=5 AND $post[warning_level]>0">
<a href='Warn.php?do=ViewMyWarnings'>View your Warnings</a> ?
</if>
</if>
<if condition="$hierarchical=='Yes'">
<if condition="($post[usergroupid]!=6 AND $post[usergroupid]!=5 AND $post[usergroupid]!=7 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])) OR ($post[usergroupid]==7 AND can_moderate($forum[forumid], '', $bbuserinfo[userid]) AND $bbuserinfo[usergroupid]==5) OR
($bbuserinfo[usergroupid]==6 AND $post[usergroupid]!=6)">
<a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[username]</a> ?
</if>
<if condition="($post[usergroupid]!=6 AND $post[usergroupid]!=5 AND $post[usergroupid]!=7 AND ($bbuserinfo[usergroupid]==7 OR $bbuserinfo[usergroupid]==5)) OR ($post[usergroupid]==7 AND $bbuserinfo[usergroupid]==5) OR ($bbuserinfo[usergroupid]==6 AND $post[usergroupid]!=6)">
<a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[username]'s Warnings</a> ?
</if>
<if condition="$post[userid]==$bbuserinfo[userid] AND $post[usergroupid]!=6 AND $post[warning_level]>0">
<a href='Warn.php?do=ViewMyWarnings'>View your Warnings</a> ?
</if>
</if>
</if>
<if condition="THIS_SCRIPT=='showthread' AND $buttons=='Buttons'">
<if condition="$hierarchical=='No'">
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND $post[usergroupid]!=5 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])">
<a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'><input type="button" class="button" name="warn" value="Warn $post[username]" accesskey="w" onClick="window.location='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'"></a> ?
</if>
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND $post[usergroupid]!=5 AND ($bbuserinfo[usergroupid]==7 OR $bbuserinfo[usergroupid]==5 OR $bbuserinfo[usergroupid]==6)">
<a href='Warn.php?do=ViewWarnings&id=$post[userid]'><input type="button" class="button" name="warn" value="View $post[username]'s Warnings" accesskey="v" onClick="window.location='Warn.php?do=ViewWarnings&id=$post[userid]'"></a> ?
</if>
<if condition="$post[userid]==$bbuserinfo[userid] AND $post[usergroupid]!=6 AND $post[usergroupid]!=7 AND $post[usergroupid]!=5 AND $post[warning_level]>0">
<a href='Warn.php?do=ViewMyWarnings'><input type="button" class="button" name="warn" value="View Your Warnings" accesskey="v" onClick="window.location='Warn.php?do=ViewMyWarnings'"></a> ?
</if>
</if>
<if condition="$hierarchical=='Yes'">
<if condition="($post[usergroupid]!=6 AND $post[usergroupid]!=5 AND $post[usergroupid]!=7 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])) OR ($post[usergroupid]==7 AND can_moderate($forum[forumid], '', $bbuserinfo[userid]) AND $bbuserinfo[usergroupid]==5) OR
($bbuserinfo[usergroupid]==6 AND $post[usergroupid]!=6)">
<a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>
<input type="button" class="button" name="warn" value="Warn $post[username]" accesskey="w" onClick="window.location='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'"></a> ?
</if>
<if condition="($post[usergroupid]!=6 AND $post[usergroupid]!=5 AND $post[usergroupid]!=7 AND ($bbuserinfo[usergroupid]==7 OR $bbuserinfo[usergroupid]==5)) OR ($post[usergroupid]==7 AND $bbuserinfo[usergroupid]==5) OR ($bbuserinfo[usergroupid]==6 AND $post[usergroupid]!=6)">
<a href='Warn.php?do=ViewWarnings&id=$post[userid]'><input type="button" class="button" name="warn" value="View $post[username]'s Warnings" accesskey="v" onClick="window.location='Warn.php?do=ViewWarnings&id=$post[userid]'"></a> ?
</if>
<if condition="$post[userid]==$bbuserinfo[userid] AND $post[usergroupid]!=6 AND $post[warning_level]>0">
<a href='Warn.php?do=ViewMyWarnings'><input type="button" class="button" name="warn" value="View Your Warnings" accesskey="v" onClick="window.location='Warn.php?do=ViewMyWarnings'"></a> ?
</if>
</if>
</if>
<!-- end of warning system -->
<if condition="$show['postcount']">#<a href="showpost.php?$session[sessionurl]p=$post[postid]&postcount=$post[postcount]" target="new"><strong>$post[postcount]</strong></a></if>
</td>
</if>
</tr>
<tr valign="top">
<td class="alt2" width="175">
<if condition="$show['spacer']"><if condition="!$post['islastshown']"></div></if>$spacer_close</if>
<!-- / post #$post[postid] -->
Can someone please help me?
The area around line 256 reads:
PHP Code:
// ###################### Start gettemplateidcache #######################
function build_template_id_cache($styleid, $doreturn = 0, $parentids = 0)
{
// if $doreturn is 1 this function will return a list of templateids,
// otherwise it will go ahead and do the necessary update query itself
// can also take a comma-separated list of parent ids to save a SELECT query.
global $DB_site;
if ($styleid == -1)
{
// doesn't have a cache
return '';
}
if ($parentids == 0)
{
$style = $DB_site->query_first("SELECT styleid, title, parentlist
FROM " . TABLE_PREFIX . "style
WHERE styleid = $styleid");
}
else
{
$style['parentlist'] = $parentids;
}
$parents = explode(',', $style['parentlist']);
$i = sizeof($parents);
$totalparents = $i;
foreach($parents AS $setid)
{
if ($setid != -1)
{
$querySele = ",\nt$i.templateid AS templateid_$i, t$i.title AS title$i, t$i.styleid$querySele";
$queryJoin = "\nLEFT JOIN " . TABLE_PREFIX . "template AS t$i ON (t1.title=t$i.title AND t$i.styleid=$setid)$queryJoin";
$i--;
}
}
$templatelist = array();
$query1 = "
SELECT t1.templateid AS templateid_1, t1.title $querySele FROM " . TABLE_PREFIX . "template AS t1 $queryJoin WHERE t1.styleid = -1
ORDER BY t1.title
";
$templates = $DB_site->query($query1);
while ($template = $DB_site->fetch_array($templates, DBARRAY_BOTH))
{
for ($tid = $totalparents; $tid > 0; $tid--)
{
if ($template["templateid_$tid"])
{
$templatelist["$template[title]"] = $template["templateid_$tid"];
break;
}
}
}
$customdone = array();
$query2 = "
SELECT t1.templateid, t1.title, INSTR(',$style[parentlist],', CONCAT(',', t1.styleid, ',') ) AS ordercontrol
FROM " . TABLE_PREFIX . "template AS t1
LEFT JOIN " . TABLE_PREFIX . "template AS t2 ON (t2.title=t1.title AND t2.styleid=-1)
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
Ok sorry about that. I reuploaded the functions_showthread.php and showthread.php files and reedited them and I am still getting the same error. I even get the error when I upload the back ups. SO it seems like the problem isn't even in those files.
I did a full uninstall but for some reason I am still getting these errors.
I resolved the issue myself. The issue was caused do to the postbit.
Ok sorry about that. I reuploaded the functions_showthread.php and showthread.php files and reedited them and I am still getting the same error. I even get the error when I upload the back ups. SO it seems like the problem isn't even in those files.
I did a full uninstall but for some reason I am still getting these errors.
I resolved the issue myself. The issue was caused do to the postbit.