Jump to content

Help with looping variables


budeboy

Recommended Posts

im trying to write a script that echos information in variables using a loop I know the code below is wrong but its the best way i could describe the sort o thing im trying to do

[code]
$i = 1;
while($i < 20){
echo "$week$i";
}
[/code]

is the sort of thing im trying to do is there a way to do a loop that echos variable $week1 then $week2 and so on intill $i = 20.
Link to comment
https://forums.phpfreaks.com/topic/3933-help-with-looping-variables/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.