posted 12 years ago
Dear friends,
I am doing a php project. I want to create a text file in server from client and writr some data init using php.I used following code.
But it is not able to create the file.
$myFile = "test.txt";
$fh = fopen($myFile, 'w') or die("can't open file...");
$stringData = "New Stuff 1\n";
fwrite($fh, $stringData);
$stringData = "New Stuff 2\n";
fwrite($fh, $stringData);
fclose($fh);
Please share your valuable ideas and thought abt this.It is little urgent.
Thanks
Rakesh