dymanic forms
| From: | george | Date: | Tue, 06 Mar 2001 12:17:51 +0000 |
| Subject: | dymanic forms | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-42739@lists.php.net to get a copy of this message | ||
I am trying to build a form which can be geberated dynamically
by the user selecting the number of fields up to a max of 10.
just now i am using
if ($fields ==1){
echo "<input type=text name=test>";
}
elseif ($fields ==2){
echo "<input type=text name=test>";
echo "<input type=text name=test>";
}
elseif ($fields ==3){
echo "<input type=text name=test><br>";
echo "<input type=text name=test><br>";
echo "<input type=text name=test><br>";
}
there must be a better way to do this
TIA
george