Re: Re: Bug #9766 [Opn]: Slashes are removed
| From: | Justin Patrin | Date: | Fri, 12 Jan 2007 20:53:40 +0000 |
| Subject: | Re: Re: Bug #9766 [Opn]: Slashes are removed | ||
| References: | 1 2 3 | Groups: | php.pear.qa |
| Request: | Send a blank email to pear-qa+get-4153@lists.php.net to get a copy of this message | ||
On 1/12/07, Stoyan Stefanov <ssttoo@gmail.com> wrote:
Hi Jan, It maybe that the issue is somewhere else in your app, maybe with your blogging tool (is it Wordpress?). I know I have the same issue when using Wordpress, maybe it's playing with the slashes. Trying a simple example in a separate file works fine for me: require_once 'Text/Highlighter.php'; require_once 'Text/Highlighter/Renderer/Html.php'; $renderer =& new Text_Highlighter_Renderer_HTML($options); $highlighter =& Text_Highlighter::factory('php'); $highlighter->setRenderer($renderer); $result = $highlighter->highlight('<?php echo "\n"; ?>'); I usually highlight code using http://hiliteme.com and then paste the result in Wordpress. On hiliteme.com it's all fine, you can test yourself, then when pasting in WP and saving, the slash disappears.Probably wordpress incorrectly assumes that magic_quotes_gpc is always on and naively stripslashes all input. I'll be happy when magic quotes is finally gone.
On 12 Jan 2007 14:55:26 -0000, jan at ivtaco dot se <pear-qa@lists.php.net> wrote: Edit report at http://pear.php.net/bugs/bug.php?id=9766&edit=1-- Justin PatrinID: 9766User updated by: jan at ivtaco dot seReported By: jan at ivtaco dot se Status: Open Type: Bug Package: Text_HighlighterOperating System: irreleveant Package Version: 0.6.9PHP Version: IrrelevantNew Comment: Example: http://www.bolmeson.se/2007/01/08/svenska-tecken-i-utskrift-i-c/ Previous Comments: ------------------------------------------------------------------------ [2007-01-08 07:18:35] 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> ------------------------------------------------------------------------ -- Edit this bug report at http://pear.php.net/bugs/bug.php?id=9766&edit=1 -- Stoyan Stefanov http://www.phpied.com -- PEAR QA Mailing List (http://pear.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php