Alright, I need 50 results printed out on a page from a MySQL table. However, lets say theres only 20 results in the table. How would I go about printing the 20 results...but then after printing 30 more results saying "Add Me".
I hope you follow me. I'm sure its easy but my brain is fried at the moment and I need to get this script done by July 30th...
I'd appreciate any help.
Not sure what you are asking, could please try and explain it better?
You can try with something like this:
$rows = mysql_num_rows($result);
for ($i = 0; $i < 50; $i++) { if ($i <= $rows) { print mysql_result($result, $i, "field") } else { print "Add me"; }
Are you trying to print something like 50 a page? If there are less than fifty it's messing up?