PEAR is discontinued

This is a static archive preserving historical releases and metadata. No new packages or updates will be published. For updates to existing packages, or to publish new packages, please use Composer and Packagist.

Home » Text » Text_Highlighter » Bug #9766

Wordpress error

Details

Submitted2007-01-08 12:18 UTC
Fromjan at ivtaco dot se
StatusBogus
PackageText_Highlighter
PHP VersionIrrelevant
OSirreleveant
Roadmaps(Not assigned)

Comments

[2007-01-08 12:18 UTC] jan at ivtaco dot se

Description:
------------
Hi,

My Highlighter seem to remove backslashes in code. E.g. in c++ or PHP code I frequently use \n for newlines. This is displayed as only n.

If I view the source it shows:
<span class="hl-special"></span><span class="hl-string">n</span>

Instead of:

<span class="hl-special">\</span><span class="hl-string">n</span>

[2007-01-12 14:55 UTC] jan at ivtaco dot se

Example:

http://www.bolmeson.se/2007/01/08/svenska-tecken-i-utskrift-i-c/

[2007-01-15 21:31 UTC] stoyan at php dot net

Hi Jan,

This seems to be a problem with WordPress and magic quotes maybe. I couldn't reproduce the issue using Text_Highlighter alone.

You can do this test in your WP:
<pre>\n</pre>
The slash will be stripped from the source when you preview your post.

Best regards,
Stoyan

[2007-01-15 23:28 UTC] jan at ivtaco dot se

Yes, indeed this was a Wordpress error. I am sorry for the false bug report... :(

//jan