Hello,
I'm trying to skip a line every 'x' queries that gets displayed. I can get the records to show but I can not skip a line every 'x' query shown. I've tried using javascript and php but can not get it to work. Can someone plz help or give me some clue how to do this?
Here is the code I am using. Thank you in advanced.

$i = 0;
while($row=mysql_fetch_array($result, MYSQL_NUM)) {
   if($i % 2 !0)
    {
    echo "<br/>";
    }
    echo "$row";
}

try:

$i = 0;
while($row=mysql_fetch_array($result, MYSQL_NUM)) {
    echo "$row[0]";
   if( !(++$i % 2) )
    {
      echo "<br />";
    }
}

Worked Perfectly thank you hielo

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.