Project

General

Profile

« Previous | Next » 

Revision 1638

Added by darkviper over 12 years ago

config.php added define to set admin-directory

View differences:

initialize.php
50 50
		$_SERVER['HTTP_REFERER'] = $sTmpReferer;
51 51
	}
52 52

  
53
if( !defined('ADMIN_URL')) { define('ADMIN_URL', WB_URL.'/admin'); }
53
if( !defined('ADMIN_DIRECTORY')) { define('ADMIN_DIRECTORY', 'admin'); }
54
if(!preg_match('/xx[a-z0-9_][a-z0-9_\-\.]+/i', 'xx'.ADMIN_DIRECTORY)) {
55
	throw new RuntimeException('Invalid admin-directory: ' . ADMIN_DIRECTORY);
56
}
57

  
58
if( !defined('ADMIN_URL')) { define('ADMIN_URL', WB_URL.'/'.ADMIN_DIRECTORY); }
54 59
if( !defined('WB_PATH')) { define('WB_PATH', dirname(dirname(__FILE__))); }
55
if( !defined('ADMIN_PATH')) { define('ADMIN_PATH', WB_PATH.'/admin'); }
60
if( !defined('ADMIN_PATH')) { define('ADMIN_PATH', WB_PATH.'/'.ADMIN_DIRECTORY); }
56 61

  
57 62
if (file_exists(WB_PATH.'/framework/class.database.php')) {
58 63
	// sanitize $_SERVER['HTTP_REFERER']

Also available in: Unified diff