Re: sprintf %s string /or " Why on earth do I only get ONE char displayed???"

From: Date: Thu, 16 Nov 2000 14:25:01 +0000
Subject: Re: sprintf %s string /or " Why on earth do I only get ONE char displayed???"
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-25696@lists.php.net to get a copy of this message
> function display_collumn ($label, $row, $editable) > { // ------------------------ // insert here: global $col_name; // or pass it as a parameter // ------------------------ > print ("<TR>\n"); > printf ("<TD>%s</TD>\n", htmlspecialchars ($label)); > $value = htmlspecialchars ($row[$col_name]); > if ($editable) #DISPLAY AS EDIT FIELDS > { > $str = sprintf ("<INPUT TYPE=text NAME=\"row[%s]\"", $col_name); > $str .= sprintf (" VALUE=\"%s\" SIZE=\"50\">\n", $value); > } > > else #DISPLAY AS READ ONLY > $str = $value; > printf ("<TD>%s</TD>\n", $str); > print ("</TR>\n"); > } > > Thx in advance, > > Al -- Mit freundlichen Grüssen s.m. --9monate.de------------------------ Sascha Mantscheff Bruenglinghausen D-51588 Nuembrecht Fon +49-171-620 0380 Fax +49-2291-3841 e-Mail smantscheff@9monate.de ------------------------------------

« previous php.general (#25696) next »