Hi,
I need to add some strings to two files in a Unix enviroment.
I have used the following working PHP code:
$fp=fopen($filename, "a+");
fwrite($fp,"$str\n");
fclose($fp);
It does exaclty what I need: go into a new line and adds the $str that I have setup.Then make a newline.
If things are ok for the first file they are not for the 2nd: in this one I will not that a new line is initializated fro the first record, I need only to add a space to previous word and then the string without going down one row, neither before, neither later.
For the last problem is only needed to delete the \n, but for the first ?
Is it possible ? How ?
Thank you.
Fabio