[Bb-trac] Re: [bbPress] #585: Multibyte Tags redirect badly or Tag not found

bbPress bb-trac at lists.bbpress.org
Sun Apr 22 11:06:00 GMT 2007


#585: Multibyte Tags redirect badly or Tag not found
---------------------------------------+------------------------------------
 Reporter:  mdawaffe                   |        Owner:  yujin   
     Type:  defect                     |       Status:  assigned
 Priority:  normal                     |    Milestone:  1.0     
Component:  i18n/l10n                  |      Version:  0.8     
 Severity:  normal                     |   Resolution:          
 Keywords:  multibyte utf8 uri encode  |  
---------------------------------------+------------------------------------
Changes (by yujin):

  * keywords:  multibyte utf8 => multibyte utf8 uri encode
  * owner:  => yujin
  * status:  new => assigned
  * component:  Administration => i18n/l10n

Comment:

 > It seems some browsers or servers (or some combinations) don't like the
 way bbPress deals with multibyte tags.

 I guess bbPress should encode the URIs with multibyte characters.  Some
 browsers automatically do so when they encounter non-encoded links but you
 should not expect this to all the other browsers.  "Should be:" in debug
 code should be encoded;-p

 Adding a line in <code>bb_repermalink)0</code> as shown below seems to be
 working so far but there may be a side effect .  Plus, I don't know what
 will happen in charsets other than utf-8.  I expect someone will fix this
 in more proper way.

 <code>bb_repermalink()</code> in file <code>bb-
 includes/functions.php</code>
 <blockquote><code>
 $domain = bb_get_option('domain');
 $domain = preg_replace('/^https?/', '', $domain);
 $check = preg_replace( '|^.*' . trim($domain, ' /' ) . '|', '',
 $permalink, 1 );
 $check = utf8_uri_encode($check); // add this line
 </code></blockquote>

 I hope this will help you.

-- 
Ticket URL: <http://trac.bbpress.org/ticket/585#comment:4>
bbPress <http://bbpress.org/>
Innovative forum development


More information about the Bb-trac mailing list