I am sending this to the ZopeXmlMethods-user list,
in hopes others may find it useful.
--Craeg
>> Expéditeur d'origine: Craeg Strong tr...@ar...)
>> Date: 04/08/03 14:06
>>
>> Hello:
>>
>> Have you tried
>> creating an object on the fly?
>> Why don't you try creating a DTMLMethod or DTMLDocument,
>> pass it your string, and use it for XSLTMethod.
>> It is only a line or two of python code. See the
>> examples of creating objects from strings
>> in Generators.py
>>
>> Alternatively,
>> As a hack, you could try to duplicate what
>> XSLTMethod does in its transform() method,
>> because ultimately it is operating on
>> strings any way...
>>
>> HTH,
>>
>> --Craeg
>>
>> > Craeg,
>> >
> > If you have a moment --
>> >
>> > I have been trying to post this to SF, but it has been down all day
>> > today. I was wondering if you could shine some light on a subject for me.
>> > I am trying to use an XSLT Method to render HTML (from XML) on the fly.
>> >
>> > The syntax for doing this looks like: <dtml-var
>> > expr="myobject.myxsltmethod(this(), REQUEST)">
>> >
>> > It seems that the XSLT Methods will only go after real objects in Zope. I
>> > would like to have users copy-and-paste XML code into a textarea box, click
>> > "submit" and have it convert the code into HTML (there are concepts I would
>> > like to build on that as well).
>> >
>> > Is there anyway to call a myxsltmethod against a non-object (ex. data from
>> > the textarea of a form)? I really appreciate and value your help.
>> >
>> > Thanks a lot - Matt
|