[dokuwiki] Re: quotation marks always goes escaped

Arthit Suriyawongkul writes:

On 07/11/2007, Andreas Gohr <andi@xxxxxxxxxxxxxx> wrote:
Arthit Suriyawongkul writes:
> On 07/11/2007, Arthit Suriyawongkul <arthit@xxxxxxxxx> wrote:
>> whenever I type " or ' in my dokuwiki ( http://cc.in.th/wiki/ )
>> it will always be converted to \" and \' when I save the page.
> I also installed a modified version of Mark Cunningham's WordPress
> authentication.
> in the code, there're few lines that call
> remove_magic_quotes( ) for $GET, $POST, and several vars.

Yes. Both systems, DokuWiki and WordPress handle the stupid MagicQuote
setting resulting in double encoding. Simply disabling magic quotes in your
PHP config should fix the problem

unfortunately, I use a shared hosting service. And thus can't change
the php.ini.

so i decided to change this code (in inc/auth/wordpress.class.php):

The following might be a better solution. Just add the following line to your wordpress file right after it stripped the magic quotes.

define('MAGIC_QUOTES_STRIPPED',1);

It should prevent double fixing.

Andi


--
DokuWiki mailing list - more info at
http://wiki.splitbrain.org/wiki:mailinglist

Other related posts: