title: smarty - replace multiple values instead of only one
body: <p>documentation: <a href="http://www.smarty.net/docsv2/en/language.modifier.replace.tpl" rel="nofollow">http://www.smarty.net/docsv2/en/language.modifier.replace.tpl</a></p>
  
  <p>Instead of replacing a single value, i would like to change multiple values. In the documentation it says the str_replace is the same as php's str_replace. Then how would i perform the following smarty wise?</p>
  
  <pre><code>$letters = array('a', 'p');
  $fruit   = array('apple', 'pear');
  $text    = 'a p';
  $output  = str_replace($letters, $fruit, $text);
  </code></pre>