[plt-scheme] using pi structs in xml.ss
On Tue, Nov 21, 2006 at 10:22:12AM -0500, Jay McCarthy wrote:
> Rather than using make-pi, you can use make-pcdata or make-cdata. The
> xexpr->xml function will not quote the strings in these structures.
I substituted make-cdata for make-pi, and have the same problem.
> >If I leave the pi struct as above, I get the error
> >
> >srep->attribute: expected (list Symbol String) given (value (php "echo
> >$var;"))
make-pi and make-cdata both work as expected when constructing a normal php
section. The problem I'm running into is placing these structs into an
attribute's value. the srep->attribute proc (called by xexpr->xml) chokes
when the value portion is not a string. This is the case if I pass either
a pi-struct or a cdata-struct. If, on the other hand, I pass the string
containing "<" or ">" chars, they get transformed to the entity equivalents.
Wayne