I would net your help concerning an issue I'm currently having with PHP
Here is the Code:
<?php
$ics_file = 'schedule.ics';
if (is_writable($ics_file)) {
if (!$handle = fopen($ics_file, 'w')) {
echo "Cannot open file ($ics_file)\n\n";
exit;
}
# Write $ics_contents to opened file
if (fwrite($handle, "foobar") === FALSE) {
echo "Cannot write to file ($ics_file)\n\n";
exit;
}
# echo "Success, wrote to <b>schedule.ics</b><br>\n\n";
fclose($handle);
} else {
echo "The file <b>$ics_file</b> is not writable\n\n";
}
?>
On my Webpage I always receive "The file schedule.ics is not writable" so it can't access the File. Could you kindly give me a hint into the right direction?