[wp-trac] [WordPress Trac] #16957: wpuntexturize - problem with numbers and non-breaking spaces

WordPress Trac wp-trac at lists.automattic.com
Thu Mar 24 10:21:33 UTC 2011


#16957: wpuntexturize - problem with numbers and non-breaking spaces
--------------------------+-----------------------------
 Reporter:  pavelevap     |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Formatting    |    Version:  3.1
 Severity:  normal        |   Keywords:
--------------------------+-----------------------------
 1) Insert following code into HTML editor and publish.

 {{{
 New <strong>Year "2011" will be</strong> fantastic.
 }}}

 Then look at website:

 {{{
 <p>New <strong>Year &#8221;2011&#8243; will be</strong> fantastic.</p>
 }}}

 You can see wrong html quotes.

 2) I also worked with TinyMCE editor (only writing simple text,
 paragraphs, strong, moving some parts of text by CTRL+C and CTRL+V). But
 after publishing, there were hidden non-breaking spaces in text. There
 were on different places, for example before "(" and after characters ".",
 "í", "é", etc. But they were random. I am not sure how it can be caused?
 Non-breaking strings were not visible and also not transformed into &nbsp;
 HTML entity on website. I noticed them only in HEX editor, when examining
 HTML source code (C2 A0).

 Of course, when these non-breaking spaces were before (or after) quotes,
 then quotes were not recognized regurarly by wpuntexturize, example:

 {{{
 Nemám žádné "úžasné" schopnosti.
 }}}

 Is transformed by wpuntexturize into:


 {{{
 <p>Nemám žádné &#8221;úžasné&#8221 schopnosti</p>.
 }}}

 You can see wrong open quote:

 {{{
 instead of &#8220 there is &#8221;
 }}}

 But only when hidden non-breaking space (C2 A0) is between žádné a
 "úžasné".

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/16957>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list