[Tutor] Questions on CGI script
Ms Soo Chong
s4046441 at student.uq.edu.au
Sat Aug 21 15:10:23 CEST 2004
Kent, thank you so much for your reply. I will take a good
look of the cgi-shell and try it out tommorrow morning.
I will send you the Server Error if I happened to meet it
again (hopefully NOT).
Anyway, should I create another .html file for the form or
type it in the script?
Thank you anyway for your help.
----- Original Message -----
From: Kent Johnson <kent_johnson at skillsoft.com>
Date: Saturday, August 21, 2004 10:44 pm
Subject: Re: [Tutor] Questions on CGI script
> What are the details of the Server Error?
> VoidSpace has a few CGI examples you could look at.
> cgi-shell is very simple example - it creates a form with one
> entry field
> that accepts a shell command. When you submit the form it executes
> command and shows you the result.
> nangram is a more complex example -
> At 08:53 AM 8/21/2004 +1000, Ms Soo Chong wrote:
> >Thanks Kent for the useful example but I'm still having some problem.
> >I tried the typing the code (from the webpage) and generate it,
> hope to
> >see some output
> >and learn from there. But it shows Server Error on the web
> browser. (After
> >through the example - Writing CGI programs in python, I thought I
> >understand whats
> >going on but in fact maybe not, since I still failed to generate
> a form
> >and output.)
> >I wanna to display a text box where user type their query msg and
> a submit
> >box to
> >process the query. Should I create another html file and open in
> read mode
> >in my actual script? Then,
> >import cgi
> >form = cgi.FieldStorage()
> >It may be simple to alot of people but sorry I don't really
> understand the
> >of writing a cgi script. Can someone please help me by giving a
> >example on
> >generating a search and displaying the result? Greatly appreciated.
> >I have been trying for the past two days without bothering python
> >but I still can't get it done. HELP.
> >Thank you in advance.
> >Tutor maillist - Tutor at python.org
More information about the Tutor