logo
Home XtGem- Templates- XtScript- bottom
Find all occurrences of a case insensitive sub-string within a string and replace them with another sub-string
[...] = optional ... = your value
[var $... = ]call str_ireplace $subject=…; $search=…; $replace[=…]
Show in textarea
<!--parser:xtscript-->
var $input = foO bar
var $this = oo
var $that = Oo
var $output = call str_ireplace $subject=$input; $search=$this; $replace=$that
print input = $input<br />
print output = $output
<!--/parser:xtscript-->
Show in textarea
Reload
input = foO bar
output = fOo bar
Powered by XtGem
About us Contact Forum top