Trying to create backups using PHP.
$filename = getcwd() . "/backup/" . $slug . date("Y-m-d-h:i:sa") . ".inc";
echo $filename;
file_put_contents($filename, $content);
Expected output filenames:
myfile2014-02-13-4:53:04pm.inc
myfile2014-02-13-4:54:29pm.inc
Actual output filenames:
T6L3PF~C.INC
TAT6YB~L.INC
Also, it is taking a really long time to create the file. This is the really strange thing: I'm also creating another file in the same script--except not in the backup directory.
$filename = getcwd() . "/" . $slug . ".html";
file_put_contents($filename, $content);
It always works perfectly and always is created instantly, no delay.
myfile.html
The backup file isn't created for over a minute, even though it precedes the .html
part of the script!