// Copyright 2011 JMB Software, Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. require_once 'includes/functions.php'; if ($_REQUEST['r'] == 'btl') { build_all_toplists(); return; } // Recompile templates on first access if (!isset($C['base_url'])) { recompile_templates(); } headers_no_cache(); prepare_request(); if (file_exists('reset-access.php') || file_exists('../auto-install.php')) { echo '<div style="font-weight: bold; color: red; font-size: 14pt; text-align: center;">' . 'The auto-install.php and cp/reset-access.php files must be removed from your server before you can access the control panel' . '</div>'; exit; } if (($auth_error = cp_authenticate()) === true) { cp_exec($_REQUEST['r'], '_xStatsOverallShow'); } else {
function _xToplistsBuildAll() { build_all_toplists(); JSON::Success(array(JSON_KEY_MESSAGE => 'All toplists have been built<br />If one or more of your toplists does not get generated, check the logs/error.log file for possible error messages')); }