[Zope] Remote scripting?
Eric Walstad
eric@walstads.net
Tue, 14 Aug 2001 10:11:52 -0700
Hi Ren=E9,
I followed examples in the book "Core Web Programming" by Marty Hall =
to make
a java applet that talks to my Zope server. It's been a long time si=
nce
I've looked at the code, but in a nutshell, the Java Applet does the
following:
1. Create a URL object that points to the DTML Method or Script that=
will
handle the request
2. Create a Connection object
3. Open the connection
4. Create a PrintStream object for sending the request to the server
5. Send the request to the server (I used println())
6. Close the output
7. Create a DataInputStream object to receive Zope's response
8. Read in Zope's data (I used readLine())
9. Close the input stream
10. Process the data that Zope sent
11. Rinse, repeat
All my applet does is redirect based on what Zope sends back to it, b=
ut it
would be easy enough to repopulate a list box with Zope data.
Hope that helps,
Eric.
PS, it's considered good form to send only "plain text" messages to t=
he
mailing list.
-----Original Message-----
=46rom: zope-admin@zope.org [mailto:zope-admin@zope.org]On Behalf Of =
Ren=E9
Olsthoorn
Sent: Tuesday, August 14, 2001 2:44 AM
To: 'zope@zope.org'
Subject: [Zope] Remote scripting?
Hello,
Remote Scripting means: calling server-side code from a client-side s=
cript
without causing the active page to be reloaded.
(for more information see http://www.ashleyit.com/rs/)
The website mentioned above contains an HTML page which contains two
comboboxes. The choices offered in the second combobox are calculated=
on the
server, depending on the choice that the user makes in the first comb=
obox.
The values of the second combobox are retrieved from the server by
communicating with a java-servlet, and all this is done without reloa=
ding
the active page. (using DHTML, ofcourse).
Has anyone done such a thing with Zope, in stead of a java-servlet?
Cheers,
Ren=E9 Olsthoorn,
Mediasystemen,
The Netherlands.