giup code fix loi br ở sb

9 bài đăng
10.08.2016 / 10:54
thanhtung698
Bài đăng: 687
Member
http://taolap.net

Code này đưa zô toan lo i br

{%macro resmile(msg)%}{%set msgs=msg|split('<img src="')%}{%for i in 0..msgs|length%}{%if 'alt="' in msgs[i]%}{{msgs[i]|split('alt="')[1]|split('"/>')[0]}}{{msgs[i]|split('alt="')[1]|split('"/>')[1]}}{%else%}{{msgs[i]}}{%endif%}{%endfor%}{%endmacro%}{%import _self as thaian2009%}{{_self.env.addGlobal('thaian2009',thaian2009)}}

[IMAGE]
10.08.2016 / 11:01
HuyAnh
Bài đăng: 1142
Member
https://www.facebook.com/boduyvidai9999/videos/219

sb có dụ lỗi br à :v

10.08.2016 / 11:14
thaian2009
Bài đăng: 709
Member

thêm raw vào

10.08.2016 / 11:15
thanhtung698
Bài đăng: 687
Member
http://taolap.net

Ko có đều j là ko thể :12:

http://chimbuom.wap.mu xem thử đi

10.08.2016 / 11:19
thanhtung698
Bài đăng: 687
Member
http://taolap.net

Như z ak {{thaian2009.resmile(message)|raw}}

10.08.2016 / 15:12
thaian2009
Bài đăng: 709
Member
thanhtung698 đã viết

Như z ak {{thaian2009.resmile(message)|raw}}

ừa

10.08.2016 / 20:05
thanhtung698
Bài đăng: 687
Member
http://taolap.net

Thêm r vẫn lỗi

11.08.2016 / 00:10
thaian2009
Bài đăng: 709
Member
thanhtung698 đã viết

Thêm r vẫn lỗi

TWIG
  1. {{thaian2009.resmile(message)replace({'&lt;br/&gt;':'<br>'})|raw}}
11.08.2016 / 09:47
thanhtung698
Bài đăng: 687
Member
http://taolap.net
thaian2009 đã viết
TWIG
  1. {{thaian2009.resmile(message)replace({'&lt;br/&gt;':'<br>'})|raw}}

Full lỗi:apl: