I'm having trouble with one piece of my php code. My problem is I have this routeen:
---
print "<select name=\"app\" style=\"font-size: 10px\" onChange=\"location=document.jump.app.options[document.jump.app.selectedIndex].value;\" value=\"GO\">";
print "<option value=\"application\">Applications</option>";
while ($a_row = mysql_fetch_array( $applications ) ) {
$app_url=$a_row['url'];
$app_title=$a_row['description'];
print "<option value=\"$app_url\">$app_title</option>";
}
print "</select>";
---
What I need it to do though is to show this <select></select> if there is something there. If there isn't anything there I don't want anything to show up. But I can't write the code without saying "select" with nothing in it.
Help
Digatle
---
print "<select name=\"app\" style=\"font-size: 10px\" onChange=\"location=document.jump.app.options[document.jump.app.selectedIndex].value;\" value=\"GO\">";
print "<option value=\"application\">Applications</option>";
while ($a_row = mysql_fetch_array( $applications ) ) {
$app_url=$a_row['url'];
$app_title=$a_row['description'];
print "<option value=\"$app_url\">$app_title</option>";
}
print "</select>";
---
What I need it to do though is to show this <select></select> if there is something there. If there isn't anything there I don't want anything to show up. But I can't write the code without saying "select" with nothing in it.
Help
Digatle