Re: [Tutor] cgi help

2010-10-06 Thread delegbede
Got it fixed. Thanks y'all. Regards, --Original Message-- From: Dave Angel To: Dipo Elegbede Cc: tutor Subject: Re: [Tutor] cgi help Sent: Oct 6, 2010 12:30 On 2:59 PM, Dipo Elegbede wrote: > here is the code: > > http://pastebin.com/K2Fxq6ac > > kindly help me f

Re: [Tutor] cgi help

2010-10-06 Thread Dave Angel
On 2:59 PM, Dipo Elegbede wrote: here is the code: http://pastebin.com/K2Fxq6ac kindly help me figure out my mistake. It is supposed to return a table of environmental variables but it returns only the header and a blank page. thanks Care to define "return" ? How are you running this cod

Re: [Tutor] CGI HELP

2010-10-06 Thread delegbede
Yes, so I did a pastebin and resent to the group. Thanks. Sent from my BlackBerry wireless device from MTN -Original Message- From: Joel Goldstick Sender: tutor-bounces+delegbede=dudupay@python.org Date: Wed, 6 Oct 2010 05:54:03 To: tutor Subject: Re: [Tutor] CGI HELP

Re: [Tutor] CGI HELP

2010-10-06 Thread Joel Goldstick
On Wed, Oct 6, 2010 at 5:25 AM, Dipo Elegbede wrote: > Hi all, > > I wrote this code as an example from a book: > > #!c:\Python26\python.exe > # Program displaying CGI environment variables. > > import os > import cgi > > def printHeader(title): > print """Content-type: text/html > > > "-//W3C/

[Tutor] cgi help

2010-10-06 Thread Dipo Elegbede
here is the code: http://pastebin.com/K2Fxq6ac kindly help me figure out my mistake. It is supposed to return a table of environmental variables but it returns only the header and a blank page. thanks -- Elegbede Muhammed Oladipupo OCA +2348077682428 +2347042171716 www.dudupay.com Mobile Bank

[Tutor] CGI HELP

2010-10-06 Thread Dipo Elegbede
Hi all, I wrote this code as an example from a book: #!c:\Python26\python.exe # Program displaying CGI environment variables. import os import cgi def printHeader(title): print """Content-type: text/html http://www.w3.org/1999/xhtml";> %s """ % title rowNumber = 0 backgroundColour = "white

Re: [Tutor] CGI help

2005-01-18 Thread Kent Johnson
Your CGI will be run fresh each time the user submits the form. If you want data to persist between submits you have to either - save the data to a persistent store - a file or database - use a different way to handle the form - I'm not sure of all the options but I think mod_python and FastCGI b

[Tutor] CGI help

2005-01-18 Thread rowan
Im trying to make a game where in a dictionary is a list of questions and answers. If i try to output 6 at a time to a cgi script and submit will my script be reset so my delete function of not getting the same question again not work? if this doesnt make sense ill repost __

Re: [Tutor] CGI help

2005-01-04 Thread Rich Krauter
David Holland wrote: Rich, That worked although I had to set the address to :- http://127.0.0.1:8000/friends1.html Thanks. Good catch, sorry about that. I noticed you had spaces in the "how many" field in your form. Did your cgi still work? If not, I guess you figured that out by now too. Intere

[Tutor] CGI help

2005-01-04 Thread David Holland
Rich, That worked although I had to set the address to :- http://127.0.0.1:8000/friends1.html Thanks. ___ ALL-NEW Yahoo! Messenger - all new features - even more fun! http://uk.messenger.yahoo.com __

Re: [Tutor] CGI help

2005-01-03 Thread Rich Krauter
David Holland wrote: I have written my first cgi script :- The .html code is :- Friends CGI Demo (Static Screen) Friends list for:New User Enter your name> How many friends do you have ? 0 10 25 50 100 The python code is :- #!/usr/bin/env python import cgi reshtml = '''Content-Type: text/html\

Re: [Tutor] CGI help

2005-01-03 Thread Kent Johnson
It sounds like maybe you are opening the HTML directly from the filesystem? You have to install the HTML and CGI into a web server and access them through the server. The details for this will depend on the web server. Kent David Holland wrote: I have written my first cgi script :- The .html cod

[Tutor] CGI help

2005-01-03 Thread David Holland
I have written my first cgi script :- The .html code is :- Friends CGI Demo (Static Screen) Friends list for:New User Enter your name> How many friends do you have ? 0 10 25 50 100 The python code is :- #!/usr/bin/env python import cgi reshtml = '''Content-Type: text/html\n Friends CGI Demo (