[Pmwiki-users] PmWiki 0.5.23 and the old preview.php add-on

Carlo Strozzi carlos
Mon Sep 8 04:44:07 CDT 2003

After the preview code has been incrporated into PmWiki, and as
anticipated by Patrick, the old preview.php script continues to
work. At the moment, for some reason, I prefer to stick with that rather
than using the built-in one. However there is one problem with
HTML special characters, like "&" for instance. With the combination
of the new PmWiki and the old preview.php, they get encoded twice
before they are inserted in the preview textarea, so that, for instance,
the [[<<]] becomes [[&amp;&amp;]] in the output. To avoid this, I have
modified the former preview.php and disabled the call to htmlspecialchars(),
to prevent the double-encoding. Also, I have done some changes do make
the external script i18n-compliant.

I would like to ask Patrick whether he devises any potential
side-effects associated with not calling htmlspecialchars() in
preview.php, like characters not being escaped in some circumstances,
and that. As I always point-out, I am not a PHP expert (although that
may eventually change, as I keep tweaking the PmWiki code :-)

For best reading please set the Courier font.
Freedom for Business: http://swpat.ffii.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: preview-i18n.php
Type: application/x-httpd-php
Size: 4381 bytes
Desc: not available
Url : http://contra.vosn.net/pipermail/pmwiki-users_pmichaud.com/attachments/20030908/f453f533/preview-i18n.bin

More information about the pmwiki-users mailing list