With the following code I would like to create a file on the server.
<?php
date_default_timezone_set('America/Sao_Paulo');
$nomeArquivoLogDia = date('Ymd') . '-teste.log';
if (file_exists($nomeArquivoLogDia)) {
$arquivoLog = file($nomeArquivoLogDia, FILE_SKIP_EMPTY_LINES);
} else {
$arquivoLog = fopen($nomeArquivoLogDia, "w+");
}
?>
When I run php ( link ) the file is not generated.
Does anyone know how to do this?