I have a script which writest to a file, using the following code:
$fp = fopen("test1.php", "w");
fwrite("$fp", "Testing!");
fclose("$fp");
When I run it, I get the following errors:
Warning: Supplied argument is not a valid File-Handle resource in /home/mark/public_html/CreateQuiz.php on line 110
Warning: Supplied argument is not a valid File-Handle resource in /home/mark/public_html/CreateQuiz.php on line 111
Line 110 is the fwrite one, and 111 the fclose one. Why am I getting these errors?