Character encoding, firefox 1.5, and ‹/›
 
 
Post new topic   Reply to topic   printer-friendly view    phpMiX.org Forum Index -> phpBB MODs -> Select Expand BBCodes
View previous topic :: View next topic  
Author Message
dandaman32
Starter
Starter


Joined: 05 Apr 2006
Posts: 2

PostPosted: Wed Apr 05, 2006 8:29 pm    Post subject: Character encoding, firefox 1.5, and ‹/› Reply with quote

I recently installed select expand bbcodes on my test board and I found one bug. In select_expand_bbcodes.js, the characters ‹ and › appear. When these codes are displayed in Firefox they don't work because these characters are specific to UTF-8 *i think*. The characters show up in Firefox as question marks. To fix this bug, change line 48:
Code:
return '&amp;nbsp;‹&nbsp;<a class="genmed" style="text-decoration:none;" href="javascript:void(0)" onclick="SXBB[\''+this.id+'\'].'+cmd+'(\''+txt+'\');" onfocus="this.blur();"><b>'+txt+'</b></a>&amp;nbsp;›';

to:
Code:
return '&amp;nbsp;&amp;#0139;&nbsp;<a class="genmed" style="text-decoration:none;" href="javascript:void(0)" onclick="SXBB[\''+this.id+'\'].'+cmd+'(\''+txt+'\');" onfocus="this.blur();"><b>'+txt+'</b></a>&amp;nbsp;&amp;#0155;';

This will make the characters display properly in nearly every browser.

‹ dandaman32 ›
 
Back to top
View user's profile Send private message
dandaman32
Starter
Starter


Joined: 05 Apr 2006
Posts: 2

PostPosted: Wed Apr 05, 2006 10:24 pm    Post subject: Re: Character encoding, firefox 1.5, and &#0139;/&#0 Reply with quote

Dang, that didn't work. I can't edit my posts so I'll try again. The preview looked OK..

Code:
return '&nbsp;‹&nbsp;<a class="genmed" style="text-decoration:none;" href="javascript:void(0)" onclick="SXBB[\''+this.id+'\'].'+cmd+'(\''+txt+'\');" onfocus="this.blur();"><b>'+txt+'</b></a>&nbsp;›';

to:
Code:
return '&nbsp;&#0139;&nbsp;<a class="genmed" style="text-decoration:none;" href="javascript:void(0)" onclick="SXBB[\''+this.id+'\'].'+cmd+'(\''+txt+'\');" onfocus="this.blur();"><b>'+txt+'</b></a>&nbsp;&#0155;';



#0139; dandaman32 ›
 
Back to top
View user's profile Send private message
markus
[Administrator]
[Administrator]


Joined: 28 Jul 2003
Posts: 1124

PostPosted: Fri Apr 07, 2006 1:18 am    Post subject: Reply with quote

Good catch, thanks! Ok Right

I'll be sure to include your fix in any future version.

 
 
_________________
http://www.phpmix.org
 
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    phpMiX.org Forum Index -> phpBB MODs -> Select Expand BBCodes All times are GMT + 1 Hour
 
Page 1 of 1


 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum