MyBB Community Forums

Full Version: Smilies
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Is there any way to make the smilies not case sensitive? Because now :p doesn't become Toungue
One way is to go to the Admin CP and manually re-enter each smilie with capital letters (Toungue) again manually.
Then all the smilies would show up twice when you click "more smilies" in the postbit...
Try this. Open functions_post.php and find
$message = str_replace($smilie['find'], "<img src=\"".$url.$smilie['image']."\" align=\"middle\" border=\"0\" alt=\"".$smilie['name']."\" />", $message);
and replace with
$message = preg_replace('#$smilie[find]#i', "<img src=\"".$url.$smilie['image']."\" align=\"middle\" border=\"0\" alt=\"".$smilie['name']."\" />", $message);
That should work.
k776 Wrote:That should work.
Unfortunately it doesn't replace anything :/
hmm, not sure why. I'm fairly new to preg_replace. Try
$message = preg_replace("#".$smilie['find']."#i", "<img src=\"".$url.$smilie['image']."\" align=\"middle\" border=\"0\" alt=\"".$smilie['name']."\" />", $message);
Already tried that, doesn;t seem to work unfortunately...
mmmmm