Here's my script:
Code: Select all
$user=" s/".$_GET["User_ID"].";".$_GET["Name"];
if (is_writable($filename_users)) {
if (!$handle = fopen($filename_users, 'a+')) {
echo "Cannot open file ($filename_users)";
exit;
}
if (fwrite($handle, $user) === FALSE) {
echo "Cannot write to file ($filename_users)";
exit;
}
echo "Success, wrote ($user) to file ($filename_users)";
fclose($handle);
} else {
echo "The file $filename_users is not writable";
}However, everytime I try and write to it, I get the error file not writable.
Can someone point me in the direction of what file permissions I need - I have tried jsut chmod 777, but this didn't resolve it; in fact it caused a different error: cannot open file!
Any help would be greatly appreciated!
Thanks
Nunners