Hi all
I want to dynaically generate some text input boxes and then when the page is reloaded have the contents of the text boxes remain the same
this is my code at the moment
for($i=1;$i<$number_of_questions+1;$i++)
{
$question_and_answer .=\"Question $i<br><input type=\\"text\\" name=\\"question$i\\" value=\\"$here$i\\"><br>\n\";
for($x=1;$x<$number_of_answers+1;$x++)
{
$question_and_answer .=\"Answer $x\\t<input type=\\\"text\\\" name=\\\"question$i--answer$x\\\"><br>\\n\";
}
$question_and_answer .=\"<br><br>\\n\";
}
print $question_and_answer;
At the moment it only returns the number of the question. Even if i change the contents of a box the content is always the question number.
How do you dynamically generate text boxes and have the contents remain the same.
For example with a singleinput box i use
print \"<input type=\\"text\\" name=\\"box_name\\" value=\\"$box_name\\">
when i enter a value into the text box it will remain there when the page is reloaded.
Not so in a loop thought!!!
Help thisis really getting on my nerves
cheers for reading my rantings
Gary Mailer