[Petal] Petal and HTML Tidy

Jean-Michel Hiver jhiver@mkdoc.com
Thu, 8 Aug 2002 12:08:53 +0100


> However, it does generate lots of warnings about unknown attributes when I 
> use the TAL-style lanaguage. Any suggestions for configuring tidy to 
> ignore these? Also, I have found an example where tidy really screws up my 
> templates. Given the following:
>         <a 
> href="mailto:%3C?petal:var%20name=">&quot;petal:content=&quot;encode:email&
> quot;&gt;Email</a>
> 
> Tidy turns it into:
> 	<a href="mailto:<?petal:var name="email"?>" 
> petal:content="encode:email">Email</a></td>

You got it the wrong way around haven't you? :-) Effectively it's
screwed up, but that's the template's fault, not tidy's.

Anyway, the new string: modifier should be your friend.


Try:


<a href="foo" petal:attributes="href string:mailto\:${email}">Email</a>

If it does not work, tell me, because I'd see it as a bug.


A workaround to this would be:

<a href="mailto:$email">Email</a>


> Also, I never heard back about needing to pass the taint value to includes 
> statements. It seems like now that taint and all other instantiation 
> settings are now global, this setting is ignored. If this is the case, 
> docs need update.

They do... feel free to send a patch if you have the courage to,
otherwise I'll do it this coming week-end (with all the bug-fixing...).

Cheers,
-- 
IT'S TIME FOR A DIFFERENT KIND OF WEB
================================================================
  Jean-Michel Hiver - Software Director
  jhiver@mkdoc.com
  +44 (0)114 255 8097
================================================================
                                      VISIT HTTP://WWW.MKDOC.COM