Jump to content

[SOLVED] chnaging background if if statement


runnerjp

Recommended Posts

humm my $imprtant is not working...can you see where its going wrong??

$getthreads="Select * from forumtutorial_posts where parentid='0' and forum = '$forum' ORDER BY lastrepliedto DESC $max";


$getthreads2=mysql_query($getthreads) or die("Could not get threads");

while($getthreads3=mysql_fetch_array($getthreads2))

{

  $getthreads3[title]=strip_tags($getthreads3[title]);

  $getthreads3[author]=strip_tags($getthreads3[author]);
      $important=$getthreads3[important]
?>
<tr <?php if($important == 1){ echo "bgcolor='#993399'"; } else { echo "bgcolor='#F2F2F2'"; } ?>class='mainrow'><td width="3%"><? if($getthreads3[author] == $puser){ ?> <img src="http://www.runningprofiles.com/images/my folder.gif" alt="My" /> <?}   else { echo 'nooo'; } ?>

saldy that did not work in chnaging the colour buti can echo the no 0 or 1!

<?php $getthreads="Select * from forumtutorial_posts where parentid='0' and forum = '$forum' ORDER BY lastrepliedto DESC $max";


$getthreads2=mysql_query($getthreads) or die("Could not get threads");

while($getthreads3=mysql_fetch_array($getthreads2))

{

  $getthreads3[title]=strip_tags($getthreads3[title]);

  $getthreads3[author]=strip_tags($getthreads3[author]);
  $getthreads3[important]=strip_tags($getthreads3[important]);
      $important=$getthreads3['important'];
?>
<tr <?php if($important == 1){ echo "bgcolor='#993399'"; } else { echo "bgcolor='#F2F2F2'"; } ?>class='mainrow'><td width="3%"><? if($getthreads3[author] == $puser){ ?>

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.