add "urlpathinfo" escape type to escape modifier. (apache does not like %2F in the PATH_INFO)

This commit is contained in:
mohrt
2005-08-12 19:38:56 +00:00
parent ec4b82b87b
commit c847cf5547
2 changed files with 5 additions and 0 deletions

2
NEWS
View File

@@ -1,3 +1,5 @@
- add escape type "urlpathinfo" to escape modifier
Version 2.6.10 (Aug 5, 2005)
----------------------------

View File

@@ -30,6 +30,9 @@ function smarty_modifier_escape($string, $esc_type = 'html')
case 'url':
return rawurlencode($string);
case 'urlpathinfo':
return str_replace('%2F','/',rawurlencode($string));
case 'quotes':
// escape unescaped single quotes
return preg_replace("%(?<!\\\\)'%", "\\'", $string);