]> git.sur5r.net Git - contagged/blobdiff - inc/smarty/plugins/modifier.escape.php
Upgrade smarty from 2.6.18 to 2.6.30
[contagged] / inc / smarty / plugins / modifier.escape.php
index 7d3230ba73e429cb688e5e5b4906c9413df27486..a2f52b232c1316ee9b7d0a2ea70cfc41c1b012c6 100644 (file)
@@ -33,7 +33,7 @@ function smarty_modifier_escape($string, $esc_type = 'html', $char_set = 'ISO-88
 
         case 'urlpathinfo':
             return str_replace('%2F','/',rawurlencode($string));
-
+            
         case 'quotes':
             // escape unescaped single quotes
             return preg_replace("%(?<!\\\\)'%", "\\'", $string);
@@ -45,12 +45,7 @@ function smarty_modifier_escape($string, $esc_type = 'html', $char_set = 'ISO-88
                 $return .= '%' . bin2hex($string[$x]);
             }
             return $return;
-
-        case 'phone':
-            $return = str_replace('+','00',$string);
-            $return = preg_replace('/[^0-9]+/','',$return);
-            return $return;
-
+            
         case 'hexentity':
             $return = '';
             for ($x=0; $x < strlen($string); $x++) {
@@ -68,11 +63,11 @@ function smarty_modifier_escape($string, $esc_type = 'html', $char_set = 'ISO-88
         case 'javascript':
             // escape quotes and backslashes, newlines, etc.
             return strtr($string, array('\\'=>'\\\\',"'"=>"\\'",'"'=>'\\"',"\r"=>'\\r',"\n"=>'\\n','</'=>'<\/'));
-
+            
         case 'mail':
             // safe way to display e-mail address on a web page
             return str_replace(array('@', '.'),array(' [AT] ', ' [DOT] '), $string);
-
+            
         case 'nonstd':
            // escape non-standard chars, such as ms document quotes
            $_res = '';