Re: can't get printf() to work

From: Date: Sat, 28 Oct 2000 17:55:49 +0000
Subject: Re: can't get printf() to work
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-22471@lists.php.net to get a copy of this message
Hi Gary, Consider using this instead: print("<tr><td>".$myrow[i]."</td><td>"); It will probably work. Ahmad Anvari ----- Original Message ----- From: Gary To: php-general@lists.php.net Sent: Saturday, October 28, 2000 9:13 PM Subject: [PHP] can't get printf() to work Hi, I can get printf to print the result form a db. I have check the query and all is well and i use mysql_num_rows() after the queries and it gives me the correct result. Here is the latest variation of what i am using. The echo table cells works fine, not the printf. while ($myrow=mysql_fetch_array($result)); echo "<table border=2 bordercolor=#000000>\n"; echo "<b><tr><td>ID</td><td>checkbox</td><td>Username</td><td>Password</td><td>Email</td></tr></b>\n"; printf("<tr><td>%s</td><td>%s</td><td>%s</td><td>%s</td><td>%s</tr>\n",$myrow["id"],$myrow["checkbox"],$myrow["username"],$myrow["password"],$myrow["email"]); echo "</table>\n"; Thanks Gary -- The sad thing about artificial intelligence is that it lacks artifice and therefore intelligence.Jean Baudrillard (1929), French semiologist. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#22471) next »