Kuribo64
Views: 9,493,168 Home | Forums | Uploader | Wiki | Object databases | IRC
Rules/FAQ | Memberlist | Calendar | Stats | Online users | Last posts | Search
04-20-19 12:18 PM
Guest:

0 users reading Stupid PHP question regarding preg_replace | 1 bot

Main - Computers and technology - Stupid PHP question regarding preg_replace New reply


thesadtruth
Posted on 03-27-19 07:00 AM (rev. 2 of 03-27-19 07:01 AM) Link | #97479
What would the correct regular expression be in PHP to replace smilies without interfering with text? I noticed a post on my board from MarioBurger (and I think another post had the same issue) that replaced "06:30" with a :3 emoticon where the bold text is, clearly a bug.

I'd assume putting a space before the text it's meant to replace, would work, but I'm not 100% certain.

Here is the code in question (look for the function CleanUpPost where it says in the function !$noSmilies - this is probably what I'll need to edit).

Thanks for any help. :P


Main - Computers and technology - Stupid PHP question regarding preg_replace New reply

Page rendered in 0.017 seconds. (2048KB of memory used)
MySQL - queries: 28, rows: 108/108, time: 0.014 seconds.
[powered by Acmlm] Acmlmboard 2.064 (2018-07-20)
© 2005-2008 Acmlm, Xkeeper, blackhole89 et al.