Hi There! I would like a bit of help please 🙂
How can I make an array value include a variable... I'm not sure if that makes sense so I'll show you what I mean.
$array[0] = "page1.html";
$array[1] = "page2.html";
$array[2] = "page3.html";
$array[3] = "page4.html";
$number = 0;
while($number <= 3){
/* I would like the next line to create and write to the files
specified above in the array */
$open= fopen ("$buildpath/$array[$number]", 'w');
fwrite ($open, $thedata);
fclose ($open);
$number++;
}
This doesn't work, and I'm not sure what to do to fix it.
Thanks in advance for any help!
Matt