Properties in DTML Document
Hello Zopians, I updated my version of Zope and have a nice surprise, the DTML Document ! Thanxs very much Zope's developers for this new fearture. When I saw that fearture I started to change my project, I had to migrate the properties from folders to new DTML Documents, ok, no problem. But I had one new problem. I have to call an lines property from a DTML Document but I am having an error and I already tried to fix that problem but was not sucessfull. Lets see the code (the part with problem): <!--#in expr="[1,2,3,4,5,6]"--> <select name="myselect"> <!--#with "_.namespace(idx=_['sequence-index'])"--> <!--#in pr_days--> 'Here is a Property from an atual folder <!--#with "_.namespace(item=_.string.split(_['sequence-item'],'|'))"-->'Here I split a string from pr_days <OPTION VALUE="<!--#var expr="item[0]"-->" <!--#if expr="_['2000.htm'].pr_moths[idx] == item[0]"-->'Here is the problem SELECTED <!--#/if--> ><!--#var expr="item[1]"--> <!--#/with--> <!--#/in--> <!--#/with--> </select> <!--#/in--> pr_months is a lines Property in 2000.htm DTML Document but is not working. The error message is: <!-- Error type: Error value: 'string' object has no attribute 'pr_months' --> Somedoby have an idea ? Thanxs ! Ze Octavio
On Thu, 4 Mar 1999, Ze Octavio wrote:
<!--#if expr="_['2000.htm'].pr_moths[idx] == item[0]"-->'Here is the problem
Hmm I tried <!--# call "_['2000.htm'].manage_addProperty('t','t','string')"--> where 2000.htm is a DTML Document and I get the same error. It works if 2000.htm is a Folder. Either is a bug or I am missing something obvious Pavlos
Pavlos, I cant use the manage_addProperty because already exist. I want to access pr_months property in the DTML Document and not add a new one. Anyone have a sugestion for this case? Its a bug ? Thanxs. Ze Octavio Pavlos Christoforou wrote:
On Thu, 4 Mar 1999, Ze Octavio wrote:
<!--#if expr="_['2000.htm'].pr_moths[idx] == item[0]"-->'Here is the problem
Hmm
I tried <!--# call "_['2000.htm'].manage_addProperty('t','t','string')"--> where 2000.htm is a DTML Document and I get the same error. It works if 2000.htm is a Folder.
Either is a bug or I am missing something obvious
Pavlos
_______________________________________________ Zope-Dev maillist - Zope-Dev@zope.org http://www.zope.org/mailman/listinfo/zope-dev
participants (2)
-
Pavlos Christoforou -
Ze Octavio