W3C home > Mailing lists > Public > html-tidy@w3.org > October to December 2007

Re: Prevent tidy from escaping URIs

From: Bjoern Hoehrmann <derhoermi@gmx.net>
Date: Mon, 08 Oct 2007 14:25:43 +0200
To: "Steve Finkelstein" <sf@stevefink.net>
Cc: html-tidy@w3.org
Message-ID: <8b8kg31ikp9c546tbk6lp7hrt7nv5j977q@hive.bjoern.hoehrmann.de>

* Steve Finkelstein wrote:
>I'm using Tidy to clean up my HTML, and I'm running into the issue of
>it convering my URIs from:
>
><link href="<?= base_url() ?>media/js/extjs/css/ext-all.css"
>rel="stylesheet" type="text/css" media="screen" />
>
>TO:
>
><script src="%3C?=%20base_url()%20?%3Emedia/js/extjs/ext-base.js"
>type="text/javascript">
>
>Any idea what toggle there is to disable that, and more importantly,
>why is it doing that?

The switch is --fix-uri and the reason is that characters like < and
space are not allowed unescaped in attribute values. There is some
special code for PHP and ASP code, which would also prevent this, but
it's probably not triggered by "<?=".
-- 
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 
Received on Monday, 8 October 2007 12:25:57 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 3 April 2012 06:13:57 GMT