Jump to content
Updating IPB tonight Read more... ×

Archived

This topic is now archived and is closed to further replies.

natalieG

Make a ListBox

Recommended Posts

In our script, we are trying to make a list box. The browser
does not show the options. The box shows up, just no items. We did check
that the right number pf rows are in the table and if we change the
statement echoing the  option[Line 4] to just  echo $SPNAME, they display correctly.

Thanks,

NatalieG 

echo '<select name="USER">';
while ($LBOXROW=mysql_fetch_array($LBOXFIND,MYSQL_ASSOC)){
$SPNAME=$LBOXROW[SPNAME];
echo "<option value=\"$SPNAME\"></option>\n";
}//while
echo '</select>';

Share this post


Link to post
Share on other sites
change
echo "<option value=\"$SPNAME\"></option>\n";

to

echo "<option value=\"$SPNAME\">\"$SPNAME\"</option>\n";

this is more of an HTML issue then anything else :-)

Share this post


Link to post
Share on other sites

×

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.