please bare with me... i'm a newbie!
I'm trying to get fwrite to... well write to a file! and then read it to make sure. I'm using the following code:
<pre>
$filename = "http://www.mywebsite.com/test/file.txt";
$fp = @fopen($filename,"w+");
if ($fp)
{
print"The file exists!<br>";
$camStatus = "1";
fwrite($fp, $camStatus);
$contents = fgets($fp, 1);
echo "the var = $contents <br><br>";
}
else
{ print"The file does not exist"; }
fclose($fp);
</pre>
But it never actually writes to the file. And yes i know my server supports it and yes the file and folder has read/write permissions set.
thanks for any help... i'm sure it's something simple i'm over looking!