if (!empty($_GET['access'])) {
// Secure input and construct FQFN
$access = SQL_ESCAPE(strip_tags($_GET['access']));
- $target = sprintf("%slogs/%s", PATH, $access);
+ $target = sprintf("%slogs/%s", constant('PATH'), $access);
// Is the file valid and readable?
if (FILE_READABLE($target)) {
OUTPUT_HTML($OUTPUT);
// Output message
- LOAD_TEMPLATE("admin_settings_saved", false, UNKNOWN_LOGFILE_FORMAT_1.$access.UNKNOWN_LOGFILE_FORMAT_2);
+ LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_UNKNOWN_LOGFILE_FORMAT'), $access));
return;
}
exit;
} else {
// Not readable!
- LOAD_TEMPLATE("admin_settings_saved", false, LOGFILE_NOT_READABLE_1.$access.LOGFILE_NOT_READABLE_2);
+ LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('LOGFILE_NOT_READABLE'), $access));
}
} else {
// List access logfiles
// We currenly only like files with "access" as prefix, should be more flexible!
if (substr($file, 0, 6) == "access") {
// Okay, let us print it out
- OUTPUT_HTML("<li><a href=\"{!URL!}/modules.php?module=admin&what=".$GLOBALS['what']."&access=".urlencode($file)."\">".$file."</a></li>");
+ OUTPUT_HTML("<li><a href=\"{!URL!}/modules.php?module=admin&what=".$GLOBALS['what']."&access=".urlencode($file)."\">".$file."</a></li>");
}
}
closedir($handle);
OUTPUT_HTML("</ol>");
} else {
// logs directory does not exist
- LOAD_TEMPLATE("admin_settings_saved", false, ADMIN_LOGS_DIR_404_1.getConfig('logs_base').ADMIN_LOGS_DIR_404_2);
+ LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_LOGS_DIR_404'), getConfig('logs_base')));
}
}