UseBB Community

UseBB support, discussion and development

[FIXED] HTML entities get converted in CODE tags

Post Reply

Page: 1

Author Post
Member
Registered: Mar 2005
Posts: 184
Location: Hungary
& #124;
(space is intentional :P) gets converted to | for instance, see here.
_______________
Long Live Rock n' Roll!
« Last edit by Dietrich on Sun Mar 19, 2006 7:13 pm. »
Moderator
Registered: Oct 2005
Posts: 502
Location: Canada

|
·
©


oh my would you look at that it does! :p kinda weird how it didn't convert the others aswell?
Member
Registered: Mar 2005
Posts: 184
Location: Hungary
I don't know, I am a web design zealot as stated before, but this entity is kinda important for me to be non-converted. :P
_______________
Long Live Rock n' Roll!
Member
Registered: Mar 2005
Posts: 184
Location: Hungary
Anything? Don't want to seem impatient, but folks cannot post code to a development-related board.
_______________
Long Live Rock n' Roll!
Developer
Registered: Apr 2004
Posts: 2230
Location: Belgium
Well, this is almost impossible to fix. Entities get converted to allow other charsets (sent as entities when a regular charset is used) to be shown on the forum, also in code tags.

Using UTF-8 and altering the unhtml() function can fix this. Or just altering unhtml() when you are sure no other charsets are sent to a page with a different charset on your forum.
Member
Registered: Mar 2005
Posts: 184
Location: Hungary
Weird thing: it does not convert when not in CODE. :shock:
_______________
Long Live Rock n' Roll!
Developer
Registered: Apr 2004
Posts: 2230
Location: Belgium
|
|

It does.
Member
Registered: Mar 2005
Posts: 184
Location: Hungary
Indeed. But see the link I posted earlier. I am totally confused now. :shock:
_______________
Long Live Rock n' Roll!
Developer
Registered: Apr 2004
Posts: 2230
Location: Belgium
Have you looked at the source of the post?
Member
Registered: Mar 2005
Posts: 184
Location: Hungary
[size=7]
function NewUserConnected(user) if SetTo[user.iProfile] == 1 then
user:SendData("$UserCommand 1 3 ----• ShoutCastStats\Get Status $<%[mynick]>"..Command1.."[b]&[/b][b]#[/b][b]124;|")[/b]
user:SendData("$UserCommand 1 3 ----• ShoutCastStats\Toggle send to all$<%[mynick]> "..Command2.." %[line:yes/no][b]&[/b][b]#[/b][b]124;|")[/b]
end
end[/size]


Tricky. :D
_______________
Long Live Rock n' Roll!
Developer
Registered: Apr 2004
Posts: 2230
Location: Belgium
Fixed in CVS using new setting.
Member
Registered: Mar 2005
Posts: 184
Location: Hungary
Thanks a lot, man! Which files should I replace?
_______________
Long Live Rock n' Roll!
Developer
Registered: Apr 2004
Posts: 2230
Location: Belgium
You need to replace at least config.php and sources/functions.php.

Set
$conf['show_raw_entities_in_code'] = 1;
in config.php
Member
Registered: Mar 2005
Posts: 184
Location: Hungary
It works. Thanks again.
_______________
Long Live Rock n' Roll!

Post Reply

Page: 1

UseBB Community is powered by UseBB 1 Forum Software