Jump to content

Displaying data horizontally not vertically


Rifts

Recommended Posts

When I run this it outputs the data down in a straight line like this

 

name

phone

email

 

name

phone

email

 

name

phone

email

 

 

but I want to display it like this

 

name        name          name

phone        phone        phone

email        email          email

 

name        name          name

phone        phone        phone

email        email          email

 

here is my code im currently using

while($row = mysql_fetch_array($result))
  {
  echo "<div style='font-size:15px'>";
  echo "<font color='red'>Name:</font>" . " " . $row['name'] . "<br>";
  echo "<font color='red'>Number:</font>" . " " . $row['number'] . "<br>";
  echo "<font color='red'>Email:</font>" . " " . $row['email'] . "<br>";
  echo "<font color='red'>Phone:</font>" . " " . $row['phone'] . "<br>";
  echo "<font color='red'>Comments:</font>" . " " . $row['comments'] . "<br>";


  echo "<br />";
  echo "<br />";
  echo "<br />";
  echo "</div>";

  }

 

thanks

 

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.