Edit report at http://pear.php.net/bugs/bug.php?id=18625&edit=1
ID: 18625
Updated by: [email protected]
Reported By: kenorb at o2 dot pl
Summary: HTML tags followed by space are not rendered
correctly
Status: Open
Type: Bug
Package: Text_Wiki_Mediawiki
Operating System: Mac
Package Version: SVN
PHP Version: 5.3.1
Roadmap Versions:
New Comment:
Isn't there a better fix than disabling preformatted text, or do I read
the patch wrong?
Previous Comments:
------------------------------------------------------------------------
[2011-06-23 15:13:11] kenorb2
Added #patch
bug:18625;patch:fix-for-html-preformatting;revision:1308838391;.
------------------------------------------------------------------------
[2011-06-23 15:09:07] kenorb2
Description:
------------
HTML tags are not rendered correctly if are followed by spaces.
Are rendered with some weird character numbers.
Related issue:
http://drupal.org/node/1196580
Test script:
---------------
<pre>Does work!</pre>
<pre>Doesn't work!</pre>
<table>
<tr>
<td>Table doesn't work</td>
<td>Table doesn't work</td>
<td>Table doesn't work</td>
</tr>
<tr>
<td>Table does work</td>
<td>Table does work</td>
<td>Table does work</td>
</tr>
</table>
Expected result:
----------------
Table is rendered correctly.
Actual result:
--------------
Code is rendered to something as below with some weird
numbers:
<pre>Does work!</pre><br />
<pre> 6Doesn't work!7</pre><br />
<table><br />
<pre> 9
10Table doesn't work11
12Table doesn't work13
14Table doesn't work15
16</pre><br />
<tr><br />
<td>Table does work</td><br />
<td>Table does work</td><br />
<td>Table does work</td><br />
</tr><br />
</table>
How this looks like in XDebug:
=> $key = 159 pearwiki_filter/Text/Wiki.php:1081
=> $rule = 'Preformatted' pearwiki_filter/Text/Wiki.php:1082
=> $opts = array ('text' => '
\0311\031\0312\031subject\0313\031\0314\031predicate\031
5\031\0316\031object\0317\031\0318\031\n ...
pearwiki_filter/Text/Wiki.php:1083
------------------------------------------------------------------------
--
Edit this bug report at http://pear.php.net/bugs/bug.php?id=18625&edit=1
lmpx.com only provides a reader for public news (NNTP) servers. It is not
affiliated with the servers or forums shown here and is not responsible for
the content of articles, which is written by their respective authors.