var sidebar_align = 'right';
var content_container_margin = parseInt('350px');
var sidebar_width = parseInt('330px');
[PHP] questions abt fwrite()
I have coded a script that do some processing every 5 mins and assign some values into a string, then writes the string into a text file.
The problem I am facing now is that, everytime it writes, it writes after the existing contents, but I would like to have it overwrites all the existing data.
Is there any easy way to do this? Tried looking through the documentation but found nothing useful there. :/
Thanks in advance for the help.
Open the file in the "w" mode, which will open the file and delete anything that's in there.
More information on available modes is at the fopen manual page.
In order to understand recursion, one must first understand recursion.
If you feel like it, you can read my blog
Signal > Noise
oh ... thanks!
I was looking at fwrite, delete and all the other functions