use "!" delimiter to make things easier
This commit is contained in:
parent
9649550463
commit
f9ca74d763
14
mod.php
14
mod.php
@ -21,16 +21,16 @@ if (get_magic_quotes_gpc()) {
|
|||||||
$query = isset($_SERVER['QUERY_STRING']) ? $_SERVER['QUERY_STRING'] : '';
|
$query = isset($_SERVER['QUERY_STRING']) ? $_SERVER['QUERY_STRING'] : '';
|
||||||
|
|
||||||
$pages = array(
|
$pages = array(
|
||||||
'/^$/' => ':?/', // redirect to dashboard
|
'!^$!' => ':?/', // redirect to dashboard
|
||||||
'/^\/$/' => 'dashboard', // dashboard
|
'!^/$!' => 'dashboard', // dashboard
|
||||||
|
|
||||||
'/^\/IP\/(.+)$/' => 'ip', // view ip address
|
'!^/IP/(.+)$!' => 'ip', // view ip address
|
||||||
|
|
||||||
// This should always be at the end:
|
// This should always be at the end:
|
||||||
'/^\/(\w+)\/' . preg_quote($config['file_index'], '/') . '?$/' => 'view_board',
|
'!^/(\w+)/' . preg_quote($config['file_index'], '!') . '?$!' => 'view_board',
|
||||||
'/^\/(\w+)\/' . str_replace('%d', '(\d+)', preg_quote($config['file_page'], '/')) . '$/' => 'view_board',
|
'!^/(\w+)/' . str_replace('%d', '(\d+)', preg_quote($config['file_page'], '!')) . '$!/' => 'view_board',
|
||||||
'/^\/(\w+)\/' . preg_quote($config['dir']['res'], '/') .
|
'!^/(\w+)/' . preg_quote($config['dir']['res'], '!') .
|
||||||
str_replace('%d', '(\d+)', preg_quote($config['file_page'], '/')) . '$/' => 'view_thread',
|
str_replace('%d', '(\d+)', preg_quote($config['file_page'], '!')) . '$!' => 'view_thread',
|
||||||
);
|
);
|
||||||
|
|
||||||
if (!$mod)
|
if (!$mod)
|
||||||
|
Loading…
Reference in New Issue
Block a user