6  * @subpackage PluginsModifierCompiler
 
  10  * Smarty strip modifier plugin
 
  14  * Purpose:  Replace all repeated spaces, newlines, tabs
 
  15  *              with a single space or supplied replacement string.<br>
 
  16  * Example:  {$var|strip} {$var|strip:" "}
 
  17  * Date:     September 25th, 2002
 
  19  * @link http://smarty.php.net/manual/en/language.modifier.strip.php strip (Smarty online manual)
 
  21  * @param array $params parameters
 
  22  * @return string with compiled code
 
  25 function smarty_modifiercompiler_strip($params, $compiler)
 
  27     if (!isset($params[1])) {
 
  30     return "preg_replace('!\s+!', {$params[1]},{$params[0]})";