Jump to content

Yucky

Members
  • Posts

    81
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

Yucky's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Fix: echo "<img src='http://datenight.netne.net/images/".$info['img']."' title='".$info['username']."' width='50' height='50'>";
  2. I used quick tags for brevity in the example. Apart from that, there's not really anything wrong with it. It seems to be the cleanest and quickest way of doing what he wanted.
  3. A bit rough, but here goes: <table width="300" border="1" cellspacing="0" cellpadding="0"> <?php foreach($yourArray as $key => $value): switch($value['yourCategory']) { case 1:$colour = "00000";break; case 2:$colour = "FFFFFF";break; } ?> <tr> <td bgcolor="#<?=$colour;?>"><?=$value['yourCategoryName']; ?></td> <td bgcolor="#<?=$colour;?>"><?=$value['yourCategoryData']; ?></td> </tr> <?php endforeach; ?> </table> Wouldn't be too hard to move the logic into the function that returns your data array.
  4. Your question doesn't really make any sense. What are you trying to achieve?
×
×
  • 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.