I have been using this code on my website for some time but today my ISP shut down my website saying that my code is generating vast amounts of log entries and adversely affecting their servers.

this is the code in the main page .
<form action="edit/usurinfo1.php" method="post">
<font face="Verdana" size="2"><strong>Update your information</strong></font><br>
<input type="text" name="content" value="<? $fn = "edit/userinfo1.txt"; print htmlspecialchars(implode("",file($fn))); ?> ">
<input type="submit" value="Change!"></form>

the above code refers to a php page with the following code.

<? $fn = "userinfo1.txt"; $content = stripslashes($_POST['content']);
$fp = fopen($fn,"w") or die ("Error opening file in write mode!");
fputs($fp,$content);
fclose($fp) or die ("Error closing file!");
echo "<meta http-equiv=\"refresh\" content=\"0; url=../edit.php\" />\n";
?>

the edit page show information on a txt file, change the info and submit the info is sent to the php file which opens the txt file, writes the new info and then closes the txt file and then returns to the edit page with the updated info displayed.

I am not a php expert and although I have been using it for a while my knowledge is very limited.

my ISP sent my an email with the following information

[Mon Feb 13 20:01:45 2012] [error] [client (link removed)] PHP Warning: fgets(): supplied argument is not a valid stream resource in (link removed)/index.php on line 144, referer: (link removed)/edit.php
[Mon Feb 13 20:01:45 2012] [error] [client (link removed)] PHP Warning: feof(): supplied argument is not a valid stream resource in (link removed)/index.php on line 143, referer: (link removed)/edit.php

and the log goes on.

Please help me to understand what is wrong and how to fix it as the website is established and I have used this snippet of code on several websites.

Regards

Dave K