David Stanek wrote:
That was me and in the svn trunk this is true. Since I don't think I
made any changes that would make this work, it should be OK in 0.8.
An example:
...
Do you get different results?
I made sure I had the svn trunk installed and tried again - still got a
different result. But I noticed that my output did not have lowercase
letters as yours, indicating I actually did not get HTML output. So I
looked for a difference and noticed that you had used the following:
kid.Template(file="junk.kid").serialize(output="html")
while I had used:
import junk.kid; print junk.serialize(output="html")
When I did it your way, I got the same result as you.
So I think this reveals another bug in kid: The generated module ignores
the output parameter, since it declares "serialize" as:
def serialize(encoding=encoding, **kw): return
Template(**kw).serialize(encoding=encoding)
This means that the output and fragment parameters are wrongly passed to
Template() and not to serialize. I think it would be better to declare
serialize() in the module as:
def serialize(encoding=encoding, fragment=fragment, output=output,
**kw): return Template(**kw).serialize(encoding=encoding,
fragment=fragment, output=output)
The same problem exists for the generate() and write() methods.
This can be trivially patched in parser.py. Does anything speak against
such a patch?
The other open issue is that the Javascript still does not work if the
output is serialized as xhtml. Does anything speak against my suggestion
to automatically add the CDATA keyword to script content in xhtml output
(always or only if the content contains < or & chars)?
-- Christoph
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
_______________________________________________
kid-template-discuss mailing list
kid-template-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kid-template-discuss