Storing the Contents of a DTML Document in a Session Variable
I have a DTML document that contains some text(no HTML or DTML) and I use it repeatedly in other DTML documents to assign default values to variables passed via a form. Is it possible to assign the contents of this document to a session variable? I am using the following but it is syntactically incorrect: <dtml-call "REQUEST.SESSION.set('test', <dtml-var no_data>)"> where no_data is the name of the DTML document that contains the text. Any help would be greatly appreciated. Thanks. - Asad
----- Original Message ----- From: "Asad Habib" <ahabib@engin.umich.edu>
I have a DTML document that contains some text(no HTML or DTML) and I use it repeatedly in other DTML documents to assign default values to variables passed via a form. Is it possible to assign the contents of this document to a session variable? I am using the following but it is syntactically incorrect:
<dtml-call "REQUEST.SESSION.set('test', <dtml-var no_data>)">
where no_data is the name of the DTML document that contains the text. Any help would be greatly appreciated. Thanks.
You need to get the contents of no_data, this might work: <dtml-call "REQUEST.SESSION.set('test', no_data.document_src() )"> if not, this should: <dtml- let e="no_data.document_src()"> <dtml-call "REQUEST.SESSION.set('test', e)"> </dtml-let> HTH Jonathan
participants (2)
-
Asad Habib -
Jonathan Hobbs