[ZPT] control of layout in ZPT

pradeep behera pradeepdeveloper at yahoo.com
Fri Jun 13 06:54:04 EDT 2003


Hi,

I want to use formulator for designing my forms. However it does not allow more than one field to be presented in the same row (a requirement for my form). 

I am using the example from this URL 
http://www.zope.org/Members/beno/HowTo/HowTo/Formulator_With_ZPT

The difficulty I am facing is that the sample code uses:

 <tr tal:define="yourname request/YourName|nothing">
   <th align="left">
    <font size=5><font face="verdana"><b>
     Your Name:
    </b></font></font>
   </th>
   <td><input type="text" name="YourName"
       tal:replace="structure python:form.YourName.render(yourname)" />
   </td>
</tr>

for each row. To  make 2 fields appear in the same row, i am trying to do this:

 
 <tr >
   <th align="left">
    <font size=5><font face="verdana"><b>
     Your Name:
    </b></font></font>
   </th>
   <td tal:define="yourname request/YourName|nothing"><input type="text" name="YourName"
       tal:replace="structure python:form.YourName.render(yourname)" />
   </td>

<td tal:define="youremail request/YourEmail|nothing">
      <font size=5><font face="verdana"><b>
     Your Email Address:
    </b></font></font>
   </td>

   <td><input type="text" name="YourEmail"
              tal:replace="structure python:form.YourEmail.render(youremail)">
   </td>
 </tr>

However I am getting errors 
Error Type NameError
Error Value name 'youremail' is not defined

Can you please help me resolve this.

Thanks
Pradeep


---------------------------------
Do you Yahoo!?
Free online calendar with sync to Outlook(TM).
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.zope.org/pipermail/zpt/attachments/20030613/bb3851fd/attachment.htm


More information about the ZPT mailing list