OK, now I get it:
$input = '<input type="hidden" name="q' . $i . '" value="' .
${$q . $i} . '">" . "\n";
print($input);
This one isn't well known so don't forget it!! ;)
Larry
Marcel <[EMAIL PROTECTED]> wrote:
> Sorry, I see that I've got the a's and q's mixed up.
> I'll try to clarify it some more by giving an example with 2 variables.
> $q1 = "first_var";
> $q2 = "second_var";
> for($i=1;$i<=2;$i++)
> {
> echo "<input type=\"hidden\" name=\"q$i\" value=\"$q$i\">\n";
> }
> The output should now be:
> <input type="hidden" name="q1" value="first_var">
> <input type="hidden" name="q2" value=\"second_var">
> Hope you can help me,
> Marcel
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php