Second slash in smiles

Support area for phpBB's mChat extension
Post Reply
dimassamid
Donor
Posts: 7
Joined: 11 Jan 2019, 04:19

Second slash in smiles

#1

Post by dimassamid » 17 Mar 2019, 00:55

Hello!

I have two smiles on a forum with codes:

Code: Select all

\(^__^)/

Code: Select all

\ (^. ^ \)
When I click to these smiles in mChat, second slash appears:

Code: Select all

 \\(^__^)/ 

Code: Select all

\\ (^. ^ \\)
so after sending the smile is not displayed correctly

Could you please help me, how to fix it? Thank you in advance!

phpBB version: 3.2.5
mChat version: 2.1.2
php version: 7.2.15

User avatar
kasimi
mChat developer
Posts: 925
Joined: 06 Oct 2016, 09:56
Location: Germany
Contact:

Re: Second slash in smiles

#2

Post by kasimi » 21 Mar 2019, 11:13

Thanks for the detailed bug report, here's the fix: https://github.com/kasimi/mChat/commit/ ... f62ff14e9b

dimassamid
Donor
Posts: 7
Joined: 11 Jan 2019, 04:19

Re: Second slash in smiles

#3

Post by dimassamid » 24 Mar 2019, 21:49

Thank you! It's working! :D

dimassamid
Donor
Posts: 7
Joined: 11 Jan 2019, 04:19

Re: Second slash in smiles

#4

Post by dimassamid » 01 May 2019, 15:30

Hello! One more problem with < > symbos .
The smile with code

Code: Select all

<3
looks like

Code: Select all

&lt;3
or

Code: Select all

(<_>)
looks like

Code: Select all

(&lt;_&gt;)

User avatar
kasimi
mChat developer
Posts: 925
Joined: 06 Oct 2016, 09:56
Location: Germany
Contact:

Re: Second slash in smiles

#5

Post by kasimi » 05 Jun 2019, 08:36

I missed the fact that the smiley code that is stored in the database is already HTML-escaped, which means no Twig escaping is necessary. Here's the fix that should make all your smilies work: https://github.com/kasimi/mChat/commit/ ... d5f590b600

dimassamid
Donor
Posts: 7
Joined: 11 Jan 2019, 04:19

Re: Second slash in smiles

#6

Post by dimassamid » 07 Jun 2019, 10:45

Thank you, kasimi! :beer:

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest