summaryrefslogtreecommitdiffstats
path: root/system
diff options
context:
space:
mode:
Diffstat (limited to 'system')
-rw-r--r--system/helpers/url_helper.php9
1 files changed, 8 insertions, 1 deletions
diff --git a/system/helpers/url_helper.php b/system/helpers/url_helper.php
index 09169e32e..6e2f7f452 100644
--- a/system/helpers/url_helper.php
+++ b/system/helpers/url_helper.php
@@ -90,7 +90,14 @@ function index_page()
*/
function anchor($uri = '', $title = '', $attributes = '')
{
- $site_url = ( ! preg_match('!^\w+://!i', $uri)) ? site_url($uri) : $uri;
+ if ( ! is_array($uri))
+ {
+ $site_url = ( ! preg_match('!^\w+://!i', $uri)) ? site_url($uri) : $uri;
+ }
+ else
+ {
+ $site_url = site_url($uri);
+ }
if ($title == '')
{