DTML Zope (element of list?)

Holger Butschek holger at butschek.com
Fri Jun 4 12:21:04 CEST 2004


Hy folks,

I have a problem in Zope (DTML).

I know, that it's a very simple problem, but I'm quite new to Zope.

I want to check, if a sequence-item of a sql-statement is in a list called 
groupsSW (this list might or might not be given by URL from a previous 
window).

Therefor, I have following code designed. I know that it doesn't work this 
way:

     <dtml-in "sqlSchlagwort(SCHLAGWORT=SCHLAGWORTSTR)">
       <table id="AutoNumber1" style="BORDER-COLLAPSE: collapse" 
borderColor="#111111" cellSpacing="0" cellPadding="3" width="60%" 
border="0">
         <tr <dtml-if sequence-even>bgcolor="#CCCCCC"</dtml-if>>
           <td width="10%"><input type="checkbox" name="groupsSW:list" 
value="&dtml-PIDSCHLAGWORT;:&dtml-SCHLAGWORT;" <dtml-if 
"&dtml-PIDSCHLAGWORT;:&dtml-SCHLAGWORT; in 
groupsSW()">checked</dtml-if></td>
           <td width="45%" align="left">
             <dtml-var SCHLAGWORT>
           </td>
         </tr>
       </table>
     <dtml-else>
       - keine Einträge vorhanden -
     </dtml-in>

If the element is in the list, then I want it CHECKED.

Please help me.

Holger Butschek

-- 
Erstellt mit M2, Operas revolutionärem E-Mail-Modul: 
http://www.opera.com/m2/



More information about the Python-list mailing list