<DIV>OK,&nbsp;I perhaps don't&nbsp;have been clear in my previous e-mail.&nbsp;</DIV>
<DIV>I need to write a little site using ZOPE3 as i using ZOPE2.</DIV>
<DIV>Really i've also write an application on ZOPE3 by ZMI (the same in ZOPE2). This application insert (by&nbsp;a form) values in a database written in MySQL.&nbsp;Typical use is&nbsp;composed by&nbsp;the following steps:</DIV>
<DIV>&nbsp;</DIV>
<DIV>1- a Page Template containing a form;</DIV>
<DIV>localhost:8080/Mercatino/iscrizione_form:</DIV>
<DIV><FONT size=2>
<P><EM>&lt;html&gt;</EM></P>
<P><EM>&lt;span </EM></P>
<P><EM>tal:replace="structure container/header"&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;body&gt;</EM></P>
<P><EM>&lt;h1&gt; Iscrizione &lt;/h1&gt;</EM></P>
<P><EM>&lt;form <STRONG>action="../iscrizione/iscrizione_html"</STRONG> method="post"&gt;</EM></P>
<P><EM>&lt;table width="100%"&gt;</EM></P>
<P><EM>&lt;tr&gt;</EM></P>
<P><EM>&lt;td&gt; Nome:&lt;/td&gt;</EM></P>
<P><EM>&lt;td&gt; &lt;input type="text" name="nome" size=20&gt;&lt;/td&gt;</EM></P>
<P><EM>&lt;/tr&gt;</EM></P>
<P><EM>&lt;tr&gt;</EM></P>
<P><EM>&lt;td&gt; Cognome:&lt;/td&gt;</EM></P>
<P><EM>&lt;td&gt; &lt;input type="text" name="cognome" size=20&gt;&lt;/td&gt;</EM></P>
<P><EM>&lt;/tr&gt;</EM></P>
<P><EM>&lt;tr&gt;</EM></P>
<P><EM>&lt;td&gt; E-mail:&lt;/td&gt;</EM></P>
<P><EM>&lt;td&gt; &lt;input type="text" name="email" size=20&gt;&lt;/td&gt;</EM></P>
<P><EM>&lt;/tr&gt;</EM></P>
<P><EM>&lt;tr&gt;</EM></P>
<P><EM>&lt;td&gt; Telefono:&lt;/td&gt;</EM></P>
<P><EM>&lt;td&gt; &lt;input type="text" name="tel" size=20&gt;&lt;/td&gt;</EM></P>
<P><EM>&lt;/tr&gt;</EM></P>
<P><EM>&lt;tr&gt;</EM></P>
<P><EM>&lt;td&gt; User:&lt;/td&gt;</EM></P>
<P><EM>&lt;td&gt; &lt;input type="text" name="user" size=20&gt;&lt;/td&gt;</EM></P>
<P><EM>&lt;/tr&gt;</EM></P>
<P><EM>&lt;tr&gt;</EM></P>
<P><EM>&lt;td&gt; Password:&lt;/td&gt;</EM></P>
<P><EM>&lt;td&gt; &lt;input type="text" name="password" size=10&gt;&lt;/td&gt;</EM></P>
<P><EM>&lt;/tr&gt;</EM></P>
<P><EM>&lt;td colspan=2&gt;</EM></P>
<P><EM>&lt;input type="submit" value="Invia"&gt;</EM></P>
<P><EM>&lt;/td&gt;</EM></P>
<P><EM>&lt;/table&gt;</EM></P>
<P><EM>&lt;/form&gt;</EM></P>
<P><EM>&lt;/body&gt;</EM></P>
<P><EM>&lt;/html&gt; </EM></P>
<P>&nbsp;</P></FONT></DIV>
<DIV>2- Previous form call a new ZPT, iscrizione_html in localhost:8080/Mercatino/iscrizione_html. <BR></DIV><FONT size=2>
<P><EM>&lt;html&gt;</EM></P>
<P><EM>&lt;span </EM></P>
<P><EM>tal:replace="structure context/../header"&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;body&gt;</EM></P>
<P><EM>&lt;p tal:content="context/zope:title"&gt;&lt;/p&gt;</EM></P>
<P><EM>&lt;span tal:condition="request/nome | nothing"&gt;</EM></P>
<P><EM>&lt;span tal:condition="request/cognome | nothing"&gt;</EM></P>
<P><EM>&lt;span tal:condition="request/email | nothing"&gt;</EM></P>
<P><EM>&lt;span tal:condition="request/tel | nothing"&gt;</EM></P>
<P><EM>&lt;span tal:condition="request/user | nothing"&gt;</EM></P>
<P><EM>&lt;span tal:condition="request/password | nothing"&gt;</EM></P>
<P><EM>&lt;p tal:define="global nome request/form/nome"&gt;&lt;/p&gt;</EM></P>
<P><EM>&lt;p tal:define="global cognome request/form/cognome"&gt;&lt;/p&gt;</EM></P>
<P><EM>&lt;p tal:define="global email request/form/email"&gt;&lt;/p&gt;</EM></P>
<P><EM>&lt;p tal:define="global tel request/form/tel"&gt;&lt;/p&gt;</EM></P>
<P><EM>&lt;p tal:define="global user request/form/user"&gt;&lt;/p&gt;</EM></P>
<P><EM>&lt;p tal:define="global password request/form/password"&gt;&lt;/p&gt;</EM></P>
<P><EM>&lt;span tal:define="sql_conn string:utility_db"&gt;</EM></P>
<P><EM>&lt;span tal:repeat="a sql: INSERT INTO utenti VALUES ('${user}', '${password}')"&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;span tal:repeat="b sql: INSERT INTO anagrafica VALUES ('${user}', '${nome}', '${cognome}', '${email}', '${tel}')"&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;h2&gt;Inserimento effettuato&lt;/h2&gt;</EM></P>
<P><EM>&lt;h2&gt;Benvenuto &lt;b tal:content="nome"&gt;nome&lt;/b&gt; &lt;b tal:content="cognome"&gt;cognome&lt;/b&gt;!&lt;br /&gt; Sei identificato come &lt;b tal:content="user"&gt;user&lt;/b&gt; &lt;/h2&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;span tal:condition="not:request/nome | nothing"&gt;</EM></P>
<P><EM>&lt;h3&gt;Non hai inserito il nome&lt;/h3&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;span tal:condition="not:request/cognome | nothing"&gt;</EM></P>
<P><EM>&lt;h3&gt;Non hai inserito il cognome&lt;/h3&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;span tal:condition="not:request/tel| nothing"&gt;</EM></P>
<P><EM>&lt;h3&gt;Non hai inserito il telefono&lt;/h3&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;span tal:condition="not:request/email | nothing"&gt;</EM></P>
<P><EM>&lt;h3&gt;Non hai inserito la mail&lt;/h3&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;span tal:condition="not:request/user | nothing"&gt;</EM></P>
<P><EM>&lt;h3&gt;Non hai inserito la user&lt;/h3&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM>&lt;span tal:condition="not:request/password | nothing"&gt;</EM></P>
<P><EM>&lt;h3&gt;Non hai inserito la password&lt;/h3&gt;</EM></P>
<P><EM>&lt;/span&gt;</EM></P>
<P><EM></EM>&nbsp;</P>
<P><EM>&lt;a href=../../iscrizione_form&gt;&lt;button&gt;Torna all'inserimento&lt;/button&gt;&lt;/a&gt;</EM></P>
<P><EM>&lt;br/&gt;&lt;br/&gt;</EM></P>
<P><EM>&lt;a href=../../index.html&gt;&lt;button&gt;Torna alla home&lt;/button&gt;&lt;/a&gt;</EM></P>
<P><EM>&lt;/body&gt;</EM></P>
<P><EM>&lt;/html&gt; </EM></P>
<DIV></FONT>This ZPT use the package sql expr (but i don't like presentation and logic in the same object...) for use a query. I use "sqlexpr" because i don't know how pass parameter to a ZSQL script (passing parameter to a ZSQL in ZOPE2 work perfectly, but in the damned ZOPE3 NO!!!). How i can pass parameters?</DIV>
<DIV>&nbsp;</DIV>
<DIV><STRONG></STRONG>3- <STRONG>THE REAL PROBLEM IS:</STRONG></DIV>
<DIV>In ZOPE2, if i want to use a PYTHON code, i insert a Python(script) into a folder and i call the script by using a ZPT (tal:repeat for example). In ZOPE2, NO PROBLEM but.....</DIV>
<DIV>In ZOPE3, I can't insert a Python script by the ZMI, but i need to write a package (__init__.py, python class, ZCML etc...). I need a lot of examples for:</DIV>
<DIV>&nbsp;&nbsp; a: write a package for my using&nbsp; and not like examples on zope.org</DIV>
<DIV>&nbsp;&nbsp; b: write the ZPT that call the package</DIV>
<DIV>&nbsp;&nbsp; c: acquisition doesn't work like ZOPE2</DIV>
<DIV>&nbsp;</DIV>
<DIV>Now I HOPE that i've been clear.</DIV>
<DIV>Thanks and sorry for my VERY VERY bad English<BR></DIV><B><I></I></B>
<DIV><B><I>Jean-Marc Orliaguet &lt;jmo@ita.chalmers.se&gt;</I></B> ha scritto: </DIV>
<BLOCKQUOTE class=replbq style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #1010ff 2px solid">Wade Leftwich wrote:<BR><BR>&gt; Stephan Richter wrote:<BR>&gt;<BR>&gt;&gt;<BR>&gt;&gt;<BR>&gt;&gt; Why not have those templates on the file system? Is there a need for<BR>&gt;&gt; users to modify those templates?<BR>&gt;<BR>&gt;<BR>&gt; Yes, users with the job description "web producers", which is to say<BR>&gt; people who can do HTML and a bit of scripting, but who do not get<BR>&gt; access to the file system. Kind of like the Zope 2 model. We even use<BR>&gt; acquisition.<BR>&gt;<BR>&gt; Also, it seemed to me unwieldy to put 50 directories in the filesystem<BR>&gt; to contain the templates for all the sites. But because of my<BR>&gt; experience with Zope 2, I assumed TTW was the best way to customize<BR>&gt; the application for each site, and I guess I should re-examine that<BR>&gt; assumption.<BR>&gt;<BR>Hi!<BR>there is indeed such a category of users, i.e. somewhere
 between<BR>filesystem developers and application users. There will be support for<BR>this kind of TTW editing in cpsskins (cf Custom Portlet), but it will be<BR>purely limited to "simple" presentation logic.<BR><BR>cf. http://www.z3lab.org/sections/front-page/design-features/custom-portlet<BR><BR>the difference with the Zope2 model I think is that "web producers" are<BR>not going to be ZPT programmers, but more like "site composers" with the<BR>ability to do minimal TTW template editing such as shown in the animation.<BR><BR>/JM<BR></BLOCKQUOTE><p>
                <hr size=1><font face="Arial" size="2"><a href="http://us.rd.yahoo.com/mail_it/taglines/*http://it.mail.yahoo.com"><b>Yahoo! Mail</b></a>: gratis 1GB per i messaggi, antispam, antivirus, POP3</font>