Loop column after 2 results


Posted on 16th Feb 2014 07:03 pm by admin

Hello All.

Here is what I have:

Did you know?Explore Trending and Topic pages for more stories like this.
Client ID Company name Client ID Company name

I then need a script to echo 2 results per row then start a new row.

I've tried many things, but never could get a second row to appear. Each row will have 4 columns.

Here is my code without the "guts" My vars will be $id and $company.

$result = mysql_query("SELECT * FROM client");
if(mysql_num_rows($result) < 1)
{
$results = 'You have 0 clients.';
}
else
{
$results = '';
$results .= '<table width="100%" border="0" cellpadding="0" cellspacing="0" align="center">';
$results .= '<tr>';

while($row = mysql_fetch_array($result))
{

}
$results .= '</table>';
}
No comments posted yet

Your Answer:

Login to answer
232 Like 12 Dislike
Previous forums Next forums
Other forums

php redirecting
i wont open a new thread but i have a question about redirecting....
i wonder why my code doesnt

Help with page encoding issue and weird characters
I'm trying to write a screen scraper and when I pull out the lines of the html file that I'm interes

Why doesn't this work? (SSH2)
This is my script:

Code: <?php
$connection = ssh2_connect('213.251.167.109', 22);

I am stumped
OK. Here is what I am trying to do. I have the conditions set, and if the conditions are met, I want

Putting double spaces instead of single spaces
Im looking at trying to replace all single spacing between fields with double spacing

At pres

please help me in this update statment
hi every one

if I have table and this data in it

id name
10

Email Processor
I have a few questions so this post will be a larger one! Sorry, but I'm a bit of a PHP newbie so be

Adding Outlook 2007 items via file upload
I am looking for a way to be able to attach an Outlook item (an email message) in an ASP.NET 3.5 app

Preg_match unknown modifyer
Hello,

Im trying to write a little script for my forums i need to get the reply from my forum

Got A Free Server :(
So I was given a free server

http://shopping.yahoo.com/p:Compaq%20ProLiant%201500%20Server:1

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash