summaryrefslogtreecommitdiffstats
path: root/system/helpers/url_helper.php
diff options
context:
space:
mode:
authorPascal Kriete <pascal.kriete@ellislab.com>2010-11-04 22:59:52 +0100
committerPascal Kriete <pascal.kriete@ellislab.com>2010-11-04 22:59:52 +0100
commite917f9be8b05c81357c1c2c9730d5060685d644d (patch)
treeb6a7d5ce8ba57b69ba61454f77829b04f2ce5974 /system/helpers/url_helper.php
parent5b2d2da5ae2e97043c6bef53e565d30e50196e2b (diff)
parente1f6e9ddff788f6a154f5f35dc117d14aeb0c484 (diff)
Automated merge with http://hg.ellislab.com/CodeIgniter2
Diffstat (limited to 'system/helpers/url_helper.php')
-rw-r--r--system/helpers/url_helper.php24
1 files changed, 12 insertions, 12 deletions
diff --git a/system/helpers/url_helper.php b/system/helpers/url_helper.php
index dad761145..e59efffec 100644
--- a/system/helpers/url_helper.php
+++ b/system/helpers/url_helper.php
@@ -70,7 +70,7 @@ if ( ! function_exists('base_url'))
/**
* Current URL
*
- * Returns the full URL (including segments) of the page where this
+ * Returns the full URL (including segments) of the page where this
* function is placed
*
* @access public
@@ -224,7 +224,7 @@ if ( ! function_exists('anchor_popup'))
* @access public
* @param string the email address
* @param string the link title
- * @param mixed any attributes
+ * @param mixed any attributes
* @return string
*/
if ( ! function_exists('mailto'))
@@ -254,7 +254,7 @@ if ( ! function_exists('mailto'))
* @access public
* @param string the email address
* @param string the link title
- * @param mixed any attributes
+ * @param mixed any attributes
* @return string
*/
if ( ! function_exists('safe_mailto'))
@@ -320,7 +320,7 @@ if ( ! function_exists('safe_mailto'))
{
$count = ($ordinal < 224) ? 2 : 3;
}
-
+
$temp[] = $ordinal;
if (count($temp) == $count)
{
@@ -369,7 +369,7 @@ if ( ! function_exists('safe_mailto'))
* @access public
* @param string the string
* @param string the type: email, url, or both
- * @param bool whether to create pop-up links
+ * @param bool whether to create pop-up links
* @return string
*/
if ( ! function_exists('auto_link'))
@@ -381,7 +381,7 @@ if ( ! function_exists('auto_link'))
if (preg_match_all("#(^|\s|\()((http(s?)://)|(www\.))(\w+[^\s\)\<]+)#i", $str, $matches))
{
$pop = ($popup == TRUE) ? " target=\"_blank\" " : "";
-
+
for ($i = 0; $i < count($matches['0']); $i++)
{
$period = '';
@@ -390,7 +390,7 @@ if ( ! function_exists('auto_link'))
$period = '.';
$matches['6'][$i] = substr($matches['6'][$i], 0, -1);
}
-
+
$str = str_replace($matches['0'][$i],
$matches['1'][$i].'<a href="http'.
$matches['4'][$i].'://'.
@@ -416,7 +416,7 @@ if ( ! function_exists('auto_link'))
$period = '.';
$matches['3'][$i] = substr($matches['3'][$i], 0, -1);
}
-
+
$str = str_replace($matches['0'][$i], safe_mailto($matches['1'][$i].'@'.$matches['2'][$i].'.'.$matches['3'][$i]).$period, $str);
}
}
@@ -447,7 +447,7 @@ if ( ! function_exists('prep_url'))
}
$url = parse_url($str);
-
+
if ( ! $url OR ! isset($url['scheme']))
{
$str = 'http://'.$str;
@@ -495,7 +495,7 @@ if ( ! function_exists('url_title'))
$replace.'$' => $replace,
'^'.$replace => $replace,
'\.+$' => ''
- );
+ );
$str = strip_tags($str);
@@ -508,7 +508,7 @@ if ( ! function_exists('url_title'))
{
$str = strtolower($str);
}
-
+
return trim(stripslashes($str));
}
}
@@ -535,7 +535,7 @@ if ( ! function_exists('redirect'))
{
$uri = site_url($uri);
}
-
+
switch($method)
{
case 'refresh' : header("Refresh:0;url=".$uri);