Hey there,
Having a little problem with a script i'm working on. I am pulling variables from a database, that I use to do a pattern search on another string.
$new = eregi_replace("$word", $insert, $old);
However, the problem I am having for example is that if $word = "template" and $old contains the word "templates" how do i get it to make an exact match, only replacing that specific word, and not variations of it?
I have tried this:
$new = eregi_replace("$word$", $insert,$old);
But it doesn't seem to find anything now, even specific matches to the word "template".
Thanks for any help!