diff options
author | Dries Buytaert <dries@buytaert.net> | 2004-01-17 11:33:58 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2004-01-17 11:33:58 +0000 |
commit | 6e1cb6e003e9127d4996f15c2e0d9bfd7120d8cc (patch) | |
tree | 364cdde3d1c5c2b787a9aa6cb9fb67101e65cbb2 /modules | |
parent | 02090ae2edf7e8c37a6c3f4e9e3e234070e56d07 (diff) | |
download | brdo-6e1cb6e003e9127d4996f15c2e0d9bfd7120d8cc.tar.gz brdo-6e1cb6e003e9127d4996f15c2e0d9bfd7120d8cc.tar.bz2 |
- Patch #5184: fixed block path and aliases. Patch by Nick.
Diffstat (limited to 'modules')
-rw-r--r-- | modules/block.module | 2 | ||||
-rw-r--r-- | modules/block/block.module | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/modules/block.module b/modules/block.module index 4743ba507..23fc3b0a1 100644 --- a/modules/block.module +++ b/modules/block.module @@ -376,7 +376,7 @@ function block_list($region) { $result = db_query("SELECT * FROM {blocks} WHERE (status = '1' OR custom = '1') ". ($region != "all" ? "AND region = %d " : "") ."ORDER BY weight, module", $region == "left" ? 0 : 1); while ($result && ($block = db_fetch_array($result))) { - if ((($block['status'] && (!$user->uid || !$block['custom'])) || ($block['custom'] && $user->block[$block['module']][$block['delta']])) && (!$block['path'] || preg_match($block['path'], str_replace("?q=", "", request_uri())))) { + if ((($block['status'] && (!$user->uid || !$block['custom'])) || ($block['custom'] && $user->block[$block['module']][$block['delta']])) && (!$block['path'] || preg_match($block['path'], "/" . $_GET["q"]))) { /* ** Check the current throttle status and see if block should be displayed diff --git a/modules/block/block.module b/modules/block/block.module index 4743ba507..23fc3b0a1 100644 --- a/modules/block/block.module +++ b/modules/block/block.module @@ -376,7 +376,7 @@ function block_list($region) { $result = db_query("SELECT * FROM {blocks} WHERE (status = '1' OR custom = '1') ". ($region != "all" ? "AND region = %d " : "") ."ORDER BY weight, module", $region == "left" ? 0 : 1); while ($result && ($block = db_fetch_array($result))) { - if ((($block['status'] && (!$user->uid || !$block['custom'])) || ($block['custom'] && $user->block[$block['module']][$block['delta']])) && (!$block['path'] || preg_match($block['path'], str_replace("?q=", "", request_uri())))) { + if ((($block['status'] && (!$user->uid || !$block['custom'])) || ($block['custom'] && $user->block[$block['module']][$block['delta']])) && (!$block['path'] || preg_match($block['path'], "/" . $_GET["q"]))) { /* ** Check the current throttle status and see if block should be displayed |