fwrite error


Posted on 16th Feb 2014 07:03 pm by admin

Hi All,
Does anyone know what is causing the error in this code?

Code: <?
$errorLog_FilePath = "error_log.txt";
$handle = @fopen($errorLog_FilePath,'a+');
$strError = "hi!";
if(!fwrite($handle, $strError)){ //this is line 5
echo('Cannot write to file');
}
?>
I get:
Parse error: syntax error, unexpected T_VARIABLE on line 5

I can't understand what is wrong with it.

No comments posted yet

Your Answer:

Login to answer
206 Like 25 Dislike
Previous forums Next forums
Other forums

Change snippet to use CURDATE
I am using time() in the snippet below, I would like to use CURDATE() and have the database setup fo

Moncler Coats Fir : 2015/2016 Moncler Asraon Astráil For Sale
[b][url=http://www.womencoats.org/ie/]moncler díol[/url][/b] [b][url=http://www.womencoats.org/ie/]

Pandora Birthstone * Angebot : Pandora Charms Verkauf Ausverkauf online shop 2015 !
[b][url=http://www.jewelrypandora.top/de/]pandora australien[/url][/b] [b]die pandora - kette[/b] pa

Material Master Update through BAPI - Follow up material not updated
Hi Experts,

I am updating the material master through a custom transaction using the BAPI

Реплика Jaeger-LeCoultre
[b][url=http://www.nicereplicawatches.top/]high quality replica watches[/url][/b] [b][url=http://ww

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Google+ Indyaspeak @ Pinterest RSS