Simple code change gives me parse errors
Posted: Sun Jan 25, 2004 11:34 am
Hi: I have been trying to figure out what is wrong with this hack I am trying to alter (per the original hack) and each time I do, I get a parse error, on lines totally different that what I am changing.
This is the original code:
In showthread.php:
Look for:
The above works perfectly, but it also allows moderators to see something I don't want them too. So the instructions were to change this:
to this:
If you need more information I will gladly supply it. I have been going over this for 2 days now. I am not a PHP writer, so if something is wrong
with the change I just don't see it.
Thanks for your help!
This is the original code:
In showthread.php:
Look for:
Code: Select all
while ($post=$DB_site->fetch_array($posts) and $counter++<$perpage) {
if ($postdoneї$postїpostid]]) {
$counter--;
continue;
} else {
$postdoneї$postїpostid]]=1;
}
$postbits .= getpostbit($post);
}
******replace it with the following:********
while ($post=$DB_site->fetch_array($posts) and $counter++<$perpage) {
if ($postdoneї$postїpostid]]) {
$counter--;
continue;
} else {
$postdoneї$postїpostid]]=1;
}
$onlinestat = "";
if(($postїmiserable] == 1) || ($postїstunned] & 4)){
if(($bbuserinfoїusergroupid] == 5) or ($bbuserinfoїusergroupid] == 6) or ($bbuserinfoїusergroupid] == 7)) {
$onlinestat = "$onlinestat<br><font color="red"><b>Miserable User</b></font>";
}
}
$postїposts]="$postїposts]$onlinestat";
$postbits .= getpostbit($post);
}Code: Select all
$onlinestat = "";
if(($postїmiserable] == 1) || ($postїstunned] & 4)){
if(($bbuserinfoїusergroupid] == 5) or ($bbuserinfoїusergroupid] == 6) or ($bbuserinfoїusergroupid] == 7)) {
$onlinestat = "$onlinestat<br><font color="red"><b>Miserable User</b></font>";
}
}Code: Select all
$onlinestat = "";
if(($postїmiserable] == 1) || ($postїstunned] & 4)){
if($bbuserinfoїusergroupid] == 6) {
$onlinestat = "$onlinestat<br><font color="red"><b>Miserable User</b></font>";
}
}with the change I just don't see it.
Thanks for your help!