Browse Source

add cellphone to friends code log

master
filesite 7 months ago
parent
commit
49b6f3ec86
  1. 4
      plugins/Common.php

4
plugins/Common.php

@ -17,10 +17,10 @@ Class Common {
$logTime = date('Y-m-d H:i:s'); $logTime = date('Y-m-d H:i:s');
$logDir = __DIR__ . '/../runtime/friendscode/'; $logDir = __DIR__ . '/../runtime/friendscode/';
$logFilename = substr($cellphone, -6) . '.log'; $logFilename = substr($cellphone, -6) . '.log';
$logOk = @error_log("{$logTime} created\n", 3, "{$logDir}{$logFilename}"); $logOk = @error_log("{$logTime} created by {$cellphone}\n", 3, "{$logDir}{$logFilename}");
if (!$logOk) { //try to mkdir if (!$logOk) { //try to mkdir
@mkdir($logDir, 0700, true); @mkdir($logDir, 0700, true);
@error_log("{$logTime} created\n", 3, "{$logDir}{$logFilename}"); @error_log("{$logTime} created by {$cellphone}\n", 3, "{$logDir}{$logFilename}");
} }
} }

Loading…
Cancel
Save