[Zope] newbie cuestion

miah34@msn.com miah34@msn.com
Fri, 22 Jun 2001 15:09:55 -0500


I was just working on a similar problem.  I'm not sure if this is the right 
way to do it, but if I'm wrong, somebody will correct me.  Try this:

<dtml-in rowsnamesmethod>
    <dtml-var expr="_.getitem(rowname,1)">
</dtml-in>

My understanding is that the '1' tells it to render the variable.  If you 
put in a '0' instead, it just displays it - probably like what you're 
getting now.  This is discussed in the Zope Book in Ch. 7: Variables and 
Advanced DTML - pg. 107

-Jeremiah




>From: "Orlando Sanchez" <osanchez_solint@hotmail.com>
>To: <zope@zope.org>
>Subject: [Zope] newbie cuestion
>Date: Fri, 22 Jun 2001 12:07:31 -0600
>
>Hi, am trying to
>
>I have a matrix of  checkboxes in a form,  something like this :
>
>rows            col1        col2                col3                col4
>row1            cb            cb                    cb                cb
>row2            cb            cb                    cb                cb
>row3            cb            cb                    cb                cb
>
>where "cb" is a checkbox
>
>the row and colum names are generated at runtime from some sql-methods
>  the code for the form is something like this :
>
><dtml-in rowsnamesmethod>
><tr>
><td><dtml-var rowname></td>
><dtml-in columnsnamesMethod>
><td align="center">
>   <input type="checkbox" name="<dtml-var rowname>" Value="<dtml-var 
>columnname>">
></td>
></dtml-in>
>
>so the question is : how can I reference the values of my checboxes in the 
>result method ?
>
>if i write
>
><dtml-in rowsnamesmethod>
>    <dtml-var rowname>
></dtml-in>
>
>it gives me the row names, but I need the values of a checbox named that 
>way, i try
>
><dtml-in rowsnamesmethod>
>    <dtml-var <dtml-var <rowname>>
></dtml-in>
>
>but that's a sintax error,
>
>what should i do ?
>
>
>Orlando Sanchez
>Sitecpro
>
>
><dtml-
>
>

_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com