inc/autopurge/purge-tsks.php -text
inc/autopurge/purge-unconfirmed.php -text
inc/cache/.htaccess -text
+inc/cache/.revision -text
inc/check-reset.php -text
inc/config-functions.php -text
inc/config.php -text
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
// You have to install first!
LOAD_URL("install.php");
}
+
// Really all done here... ;-)
+shutdown();
+
+//
?>
// Load index page
LOAD_URL("index.php");
+// Shutdown
+shutdown();
+
// [EOF]
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
// Is the extension installed?
if (!EXT_IS_ACTIVE("debug")) {
// Then abort here
- exit;
+ shutdown();
} // END - if
// Is the request parameter set?
} // END - if
// Really all done here... ;-)
+shutdown();
+
+//
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
--- /dev/null
+856
+1236367472
+0.2.1-FINAL-STELZI
+stelzi
\ No newline at end of file
* -------------------------------------------------------------------- *
* Kurzbeschreibung : Ihre Konfigurationsdaten (MySQL) *
* -------------------------------------------------------------------- *
- * *
+ * $Revision:: 856 $ *
+ * $Date:: 2009-03-06 20:24:32 +0100 (Fr, 06. Mär 2009) $ *
+ * $Tag:: 0.2.1-FINAL $ *
+ * $Author:: stelzi $ *
+ * Needs to be in all Files and every File needs "svn propset *
+ * svn:keywords Date Revision" (autoprobset!) at least!!!!!! *
* -------------------------------------------------------------------- *
* Copyright (c) 2003 - 2008 by Roland Haeder *
* For more information visit: http://www.mxchange.org *
// CFG: DEBUG-WEEKLY (comment in to test weekly reset, comment out to not test)
//define('DEBUG_WEEKLY', true);
-// When we are not installing
-if (!defined('mxchange_installing')) define('mxchange_installing', false);
-
// Your MySQL data (we don't like M$ SQL ;-) )
$MySQL = array(
// CFG: MYSQL-HOST
* Kurzbeschreibung : Definitionen und Datenfelder (hart-codertiert) *
* -------------------------------------------------------------------- *
* $Revision:: 856 $ *
- * $Date:: 2009-03-06 20:24:32 +0100 (Fr, 06. Mär 2009) $ *
+ * $Date:: 2009-03-06 20:24:32 +0100 (Fr, 06. Mär 2009) $ *
* $Tag:: 0.2.1-FINAL $ *
* $Author:: stelzi $ *
* Needs to be in all Files and every File needs "svn propset *
// Full version string: /([0-9]){1}\.([0-9]){1}\.([0-9]){1}(-(alpha|beta|pre|rc([1-3]))([0-9]+))?/
// If you understand regular expressions ^^^ you may know how I versionize... ;-)
-define('FULL_VERSION', getActualVersion('Tag'));
+//define('FULL_VERSION', getActualVersion('Tag'));
+define('FULL_VERSION', "0.2.1-FINAL");
// Replacement strings
$GLOBALS['replacer'] = array(
define('START_YDAY', MAKE_TIME(0, 0, 0, time() - getConfig('one_day')));
define('START_TDAY', MAKE_TIME(0, 0, 0, time()));
-// Current SVN revision
-define('CURR_SVN_REVISION', getActualVersion('Revision'));define('CURR_SVN_DATE' , getActualVersion('Date'));
+// Current SVN revision and date
+define('CURR_SVN_REVISION', getActualVersion('Revision'));
+define('CURR_SVN_DATE' , getActualVersion('Date'));
+
// Take a prime number which is long (if you know a longer one please try it out!)
define('_PRIME', 591623);
LOAD_TEMPLATE("runtime_fatal_table", false, $OUT);
// Abort here
- exit;
+ shutdown();
}
// Message to regular users (non-admin)
// Clear all previous SQL queries
INIT_SQLS();
+ // Are we installing?
+ if (isInstalling()) {
+ // Then silently skip this filter
+ return true;
+ } // END - if
+
// Is a database link here and not in installation mode?
if ((!SQL_IS_LINK_UP()) && (!isInstalling())) {
// Abort here
// Output HTML code
OUTPUT_HTML("");
+// Shutdown
+shutdown();
+
//
?>
LOAD_TEMPLATE("redirect_url", false, str_replace("&", "&", $URL));
LOAD_INC("inc/footer.php");
}
- exit;
+ shutdown();
}
// Wrapper for LOAD_URL but URL comes from a configuration entry
$request = "GET /" . trim($script) . " HTTP/1.1\r\n";
$request .= "Host: " . $host . "\r\n";
$request .= "Referer: " . constant('URL') . "/admin.php\r\n";
- $request .= "User-Agent: " . constant('TITLE') . "/" . constant('FULL_VERSION') . "\r\n";
+ if (defined('FULL_VERSION')) {
+ $request .= "User-Agent: " . constant('TITLE') . "/" . constant('FULL_VERSION') . "\r\n";
+ } else {
+ $request .= "User-Agent: " . constant('TITLE') . "/?.?.?\r\n";
+ }
$request .= "Content-Type: text/plain\r\n";
$request .= "Cache-Control: no-cache\r\n";
$request .= "Connection: Close\r\n\r\n";
LOAD_INC_ONCE("inc/footer.php");
// Exit explicitly
- exit;
+ shutdown();
}
// Display parsing time and number of SQL queries in footer
}
// Function to search for the last modifikated file
-function searchDirsRecoursive($dir, &$last_changed) {
+function searchDirsRecoursive ($dir, &$last_changed) {
$ds = scandir($dir); // Needs adjustment for PHP < 5.0.0!!
foreach ($ds as $d) {
$f_name = $dir.'/'.$d; // makes a proper Filename
}
}
}
-function getSearchFor()
-{
+
+function getSearchFor () {
$searchFor[] = 'Revision';
$searchFor[] = 'Date';
$searchFor[] = 'Tag';
$searchFor[] = 'Author';
return $searchFor;
-
}
-
-function getAkt_vers()
-{
+function getAkt_vers () {
$next_dir = '.';
$last_changed['path_name'] = '';
$last_changed['time'] = 0;
// Check wether we are installing
function isInstalling () {
- return (isset($GLOBALS['mxchange_installing']));
+ $installing = ((isset($GLOBALS['mxchange_installing'])) || (REQUEST_ISSET_GET('installing')));
+ //* DEBUG: */ var_dump($installing);
+ return $installing;
}
// Check wether this script is installed
return ((isset($GLOBALS['cache_instance'])) && (is_object($GLOBALS['cache_instance'])));
}
+// Our shutdown-function
+function shutdown () {
+ // Call the filter chain 'shutdown'
+ runFilterChain('shutdown', null, false);
+
+ if (SQL_IS_LINK_UP()) {
+ // Close link
+ SQL_CLOSE(__FILE__, __LINE__);
+ } elseif (!isInstalling()) {
+ // No database link
+ addFatalMessage(__FILE__, __LINE__, getMessage('NO_DB_LINK_SHUTDOWN'));
+ }
+
+ // Stop executing here
+ exit;
+}
+
//////////////////////////////////////////////////
// AUTOMATICALLY RE-GENERATED MISSING FUNCTIONS //
//////////////////////////////////////////////////
require($INC);
}
-// Call-back function for running shutdown functions and close database connection
-function __SHUTDOWN_HOOK () {
- // Call the filter chain 'shutdown'
- runFilterChain('shutdown', null, false);
-
- if (SQL_IS_LINK_UP()) {
- // Close link
- SQL_CLOSE(__FILE__, __LINE__);
- } elseif (!isInstalling()) {
- // No database link
- addFatalMessage(__FILE__, __LINE__, getMessage('NO_DB_LINK_SHUTDOWN'));
- }
-}
-
// [EOF]
?>
require($INC);
}
-// Load sql_patches here
-LOAD_EXTENSION("sql_patches");
-
// Init variables
$mysql = "";
if ((REQUEST_ISSET_POST(('mysql'))) && (is_array(REQUEST_POST('mysql')))) $mysql = REQUEST_POST('mysql');
// Output the logfile's content and exit
print($content);
- exit;
+ shutdown();
} else {
// Not readable!
LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('LOGFILE_NOT_READABLE'), $access));
imagepng($image);
imagedestroy($image);
}
- exit;
+ shutdown();
} elseif (!REQUEST_ISSET_GET(('usage'))) {
$FQFN = sprintf("%s%s/index.html",
constant('PATH'),
// Set error handler
set_error_handler('__errorHandler');
-// Register shutdown hook
-register_shutdown_function('__SHUTDOWN_HOOK');
-
// Check if the user setups his MySQL stuff...
-if ((empty($MySQL['login'])) && (!defined('mxchange_installing')) && (!REQUEST_ISSET_GET(('installing'))) && (isInstalled())) {
+if ((empty($MySQL['login'])) && (!isInstalling()) && (!REQUEST_ISSET_GET('installing')) && (isInstalled())) {
// No login entered and outside installation mode
OUTPUT_HTML("<strong>{--LANG_WARNING--}:</strong> ");
if (isInstalled()) {
LOAD_EXTENSION("sql_patches");
}
-if ((getTotalFatalErrors() > 0) && (isInstalled()) && (!defined('mxchange_installing')) && ($GLOBALS['output_mode'] != "1")) {
+if ((getTotalFatalErrors() > 0) && (isInstalled()) && (!isInstalling()) && ($GLOBALS['output_mode'] != "1")) {
// One or more fatal error(s) occur during connect...
LOAD_INC_ONCE("inc/header.php");
LOAD_INC_ONCE("inc/fatal_errors.php");
</div>
</body>
</html>\n";
-exit;
+shutdown();
//
?>
}
// All done here...
+shutdown();
+
+//
?>
* MA 02110-1301 USA *
************************************************************************/
-// Tell every module / include file we are installing
-$GLOBALS['mxchange_installing'] = true;
-
// Load security system
require("inc/libs/security_functions.php");
+// Tell every module / include file we are installing
+$GLOBALS['mxchange_installing'] = true;
+
// Init "action" and "what"
$GLOBALS['what'] = "";
$GLOBALS['action'] = "";
LOAD_INC_ONCE("inc/footer.php");
} // END - if
+// Shutdown
+shutdown();
+
//
?>
}
// All done here...
+shutdown();
+
+//
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
LOAD_URL("install.php");
}
+// Shutdown
+shutdown();
+
//
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
}
// Really all done here... ;-)
+shutdown();
+
+//
?>
LOAD_URL (URL."/index.php");
}
-// END - if
+// Shutdown
+shutdown();
+
+//
?>