This has been a nagging problem that always comes up... Here is an example as its hard to explain.
ok I want to loop though this 9 times
The variable comes from a FORM
EXAMPLE HOW IT COMES FROM FORM
<?
for ($i=0; $i < 9; $i++) {
?>
<input type="hidden" name="upload<?echo $i;?>" value="yes">
<?
}
?>
So this code is on the page the form calls
for ($i=0; $i < 9; $i++) {
echo $upload.$i; // THE VARIABLE NAMES ARE $upload0 - $upload8
}
Can I somehow use a counter variable (In this case $i) to change the variable name???
I only tried $upload.$i and $upload$i
I have no clue what else you could do??
Or do I have to code it like this
echo $upload0;
echo $upload1;
echo $upload2;
echo $upload3;
echo $upload4;
echo $upload5;
echo $upload6;
echo $upload7;
echo $upload8;
Also sorry for all the questions.. I am still a beginner trying to find my way....