[Tutor] Web app in Python: alternatives to CGI?

Terry Carroll carroll at tjc.com
Sat Apr 17 23:18:52 EDT 2004

On Sat, 17 Apr 2004, Alan Gauld wrote:

> > Is CGI my only choice?
> No there are loads of choices from ASP to Zope.
> But CGI is perfectly capable of what you ask, just
> capture the data, submit the form and display the
> results. The complexity, as you describe it, is
> all in the calculation surely?

Well, it's submit the form, capture the data; based on the data, figure 
out what additional data is needed, and then submit another form and 
capture the data; based on that data, figure out what additional data is 
required, etc.

For example, if the work was published prior to 1978, the date of the 
author's death is not needed, so I don't want to ask it.  Similarly, if 
the work was created after 1977, the date of publication is irrelevant, so 
I don't want to ask.

So I'll ask something like:
  Was the work:
   () published in 1977 or earlier;
   () created in 1978 or later;
   () created in 1977 or earlier, but not published prior to 1978;
   () don't know.

Then if the user selected "published in 1977 or earlier", the next screen 
would ask "what's the date of publication"; but if he sleected "created in 
1978 or later," the next screen would ask "is the author still alive"; if 
the third, it would go on to ask if the work was ever published.

After each of these, there is another branch to take until all the data is 

So it's not just one CGI process.  I need to save status from call to
call; cookies or something I guess.  That's what I meant by

   I need something that handles that [whether one set or another set of
   questions will be asked depends on the replies to earlier questions ]
   well, and trying to tie multiple prompts into a CGI program, using
   either cookies, hidden [data] or some other trick isn't something I'd
   really like to do.

(Not the clearest way of explaining it, I guess.)

> And the country... If you are putting it on the web you may
> have users from many countries accessing it. Something to
> consider - even if its only with a US only disclaimer...

This is US only. 

More information about the Tutor mailing list