X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Fdatabases.php;h=42c3be65247ba5be4dc10ac81b076e0cfe7a59ba;hp=a1eb89f4d174ee426102b79e583ba204eee9c621;hb=d74b665c4f1f44ef7941e8d9db8f4c9d8ea656e0;hpb=f36ab6ae1503ee54a7c9d0083a8089286d8b37ef diff --git a/inc/databases.php b/inc/databases.php index a1eb89f4d1..42c3be6524 100644 --- a/inc/databases.php +++ b/inc/databases.php @@ -10,7 +10,12 @@ * -------------------------------------------------------------------- * * Kurzbeschreibung : Definitionen und Datenfelder (hart-codertiert) * * -------------------------------------------------------------------- * - * * + * $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 * @@ -47,12 +52,12 @@ define('CODE_NO_COOKIES' , 0x006); define('CODE_CNTR_FAILED' , 0x008); define('CODE_LOGOUT_DONE' , 0x008); define('CODE_LOGOUT_FAILED' , 0x009); -define('CODE_URL_TLOCK' , 0x00A); -define('CODE_URL_FOUND' , 0x00B); -define('CODE_OVERLENGTH' , 0x00C); -define('CODE_SUBJ_URL' , 0x00D); -define('CODE_BLIST_URL' , 0x00E); -define('CODE_NO_RECS_LEFT' , 0x00F); +define('CODE_URL_TLOCK' , 0x00a); +define('CODE_URL_FOUND' , 0x00b); +define('CODE_OVERLENGTH' , 0x00c); +define('CODE_SUBJ_URL' , 0x00d); +define('CODE_BLIST_URL' , 0x00e); +define('CODE_NO_RECS_LEFT' , 0x00f); define('CODE_INVALID_TAGS' , 0x010); define('CODE_MORE_POINTS' , 0x011); define('CODE_COOKIES_DISABLED' , 0x012); @@ -63,67 +68,50 @@ define('CODE_USER_404' , 0x016); define('CODE_STATS_404' , 0x017); define('CODE_ALREADY_CONFIRMED', 0x018); define('CODE_ERROR_MAILID' , 0x019); -define('CODE_EXTENSION_PROBLEM', 0x01A); -define('CODE_MORE_RECEIVERS1' , 0x01B); -define('CODE_MORE_RECEIVERS2' , 0x01C); -define('CODE_MORE_RECEIVERS3' , 0x01D); -define('CODE_INVALID_URL' , 0x01E); -define('CODE_MENU_NOT_VALID' , 0x01F); +define('CODE_EXTENSION_PROBLEM', 0x01a); +define('CODE_MORE_RECEIVERS1' , 0x01b); +define('CODE_MORE_RECEIVERS2' , 0x01c); +define('CODE_MORE_RECEIVERS3' , 0x01d); +define('CODE_INVALID_URL' , 0x01e); +define('CODE_MENU_NOT_VALID' , 0x01f); define('CODE_LOGIN_FAILED' , 0x020); -define('CODE_BEG_SAME_AS_OWN' , 0x020); -define('CODE_UNHANDLED_STATUS' , 0x020); +define('CODE_BEG_SAME_AS_OWN' , 0x021); +define('CODE_UNHANDLED_STATUS' , 0x022); + +// Server-URL (DO NOT CHANGE THIS OR YOU CANNOT CHECK FOR UPDATES/EXTENSIONS!) +define('SERVER_URL', "http://www.mxchange.org"); // 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', "0.2.1-FINAL"); +define('FULL_VERSION', getActualVersion('Tag')); // Replacement strings -$REPLACER = array( - 'userid' => "%uid%", // User-ID - 'surname' => "%vorname%", // Surname - 'family' => "%nachname%", // Family name - 'gender' => "%anrede%", // Gender +$GLOBALS['replacer'] = array( + 'userid' => "%uid%", // User-ID + 'surname' => "%vorname%", // Surname + 'family' => "%nachname%", // Family name + 'gender' => "%anrede%", // Gender ); // One day -$_CONFIG['one_day'] = 60*60*24; +setConfigEntry('one_day', (60*60*24)); // // Timestamp for yesterday, today ... all at 00:00 am define('START_YDAY', MAKE_TIME(0, 0, 0, time() - getConfig('one_day'))); define('START_TDAY', MAKE_TIME(0, 0, 0, time())); -$COOKIES = substr(URL, strpos(substr(URL, 8), "/") + 8); -if ((strpos($COOKIES, "/") == "0") && (strpos(substr(URL, 8), "/") > 0)) { - // Script was installed into a sub directory - if (substr($COOKIES, -1) != "/") $COOKIES .= "/"; -} else { - // No more sub directories added to URL - $COOKIES = "/"; -} - -// Cookie-Path ( for lame servers... ;-) ) -define('COOKIE_PATH', $COOKIES); - -// Base directory for access logfiles -define('LOGS_BASE', "logs"); - -// Base directory for usage statistics -define('USAGE_BASE', "usage"); - -// Server-URL (DO NOT CHANGE THIS OR YOU CANNOT CHECK FOR UPDATES/EXTENSIONS!) -define('SERVER_URL', "http://www.mxchange.org"); - -// Current SVN revision -define('CURR_SVN_REVISION', "699"); +// 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); // Calculate "entropy" with the prime number (for code generation) -define('_ADD', (_PRIME * _PRIME / (pi() * getConfig('code_length') + 1))); +define('_ADD', (constant('_PRIME') * constant('_PRIME') / (pi() * getConfig('code_length') + 1))); -// Random number for e.g. "cache-buster" used in OpenX script +// Random number for e.g. the "cache-buster" used in OpenX script define('CACHE_BUSTER', mt_rand(1000000, 9999999)); // Extra title is empty by default