[Zope-dev] Javascript variables Form element values and zope
GBPark at ed.ac.uk
gbp at staffmail.ed.ac.uk
Fri Oct 3 08:34:00 EDT 2003
Hallo All,
I have this little form and I would like to know how to persuade dtml or
python to access the javascript variables in the set_p function and the
element values in the form "LOG".
I'll be thankful for any assistance.
<html><head>
<script language="JAVASCRIPT">
function set_p(a,b)
{
//
// call a zsql script mylookup which returns a single value
//
document.p.value=<dtml-call expr="mylookup(a,b)">
//
//alternatively
//document.p.value=<dtml-call
expr="mylookup(document.LOG.m.value,document.LOG.n.value)">
//
}
</script>
</head><body>
<form name="LOG">
<table>
<tr>
<td><input type=text name="m" value=""></td>
<td><input type=text name="n" value=""></td>
<td><input type=text name="p" value=""></td>
<td><input type=button value="Update P"
onclick=set_p(m.value,c.value)></td></tr></table>
</form></body></html>
Gavin
More information about the Zope-Dev
mailing list