[Zope-DB] Zope: how to execute a sql-method from within a self created form

Deniz, Metin metin.deniz@CommerzbankIB.com
Thu, 15 Nov 2001 15:40:42 +0100


Hi everybody,

i have the following problem:

i have created a form and enter some values(vorname, nachname).
After pressing the submit-button, the sql-method which is being called pops
up and expects me to enter the values once again. I would rather have the
method to execute the sql statement right away.

Below are the source code for the form and the sql-methods statement.

sql-method:
parameters: vorname nachname

INSERT INTO personen
(vorname, nachname)
VALUES
(
<dtml-sqlvar vorname type="string">,
<dtml-sqlvar nachname type="string">
)

form:

<html>
<p>
<form action="testSQL" method="submit">
Vorname <input name="vorname" width=30 value="bla">
<p>
Nachname <input name="nachname" width=30 value="tra">
<p>
<input type="SUBMIT" value="Submit Query">
</form>
</html>


Thank you very much in advance.


Metin Deniz