User Profile

Collapse

Profile Sidebar

Collapse
JustWant2Ask
JustWant2Ask
Last Activity: Aug 11 '08, 12:49 PM
Joined: Aug 9 '08
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • JustWant2Ask
    replied to python CGI struggle...
    I got it working!

    A quick explanation for people looking to solve the same problem. The code below in the plotting script reads the data passed on to the FieldStorage and converts it to a normal python dictionary.

    Code:
    form = cgi.FieldStorage()
    d={}
    for key in form:
        d[key]=form[key].value
    thanks for everyones help!...
    See more | Go to post

    Leave a comment:


  • JustWant2Ask
    replied to python CGI struggle...
    Thanks! that puts me in a complete new path...

    Where do the params go to in this case? Does it go to sys.argv[1]? how do I read them in the script that generates the chart?

    thanks!...
    See more | Go to post

    Leave a comment:


  • JustWant2Ask
    replied to python CGI struggle...
    Hi again,

    I searched a bit and found out a couple of things about GET and POST.

    Using GET will not be an option as the data to be plotted will contain potentially too many points to pass them as part of the url, and it would not be nice to see all that in the address bar either.

    So, to use post I thought I had found the way of doing it with the following lines

    Code:
    [as before]
    ...
    See more | Go to post

    Leave a comment:


  • JustWant2Ask
    replied to python CGI struggle...
    Thanks for your reply. However, I am new to cgi and web programming, and I do not understand what you mean by "using GET"... any chances for a more elaborated answer?

    Thanks!
    See more | Go to post

    Leave a comment:


  • JustWant2Ask
    started a topic python CGI struggle...

    python CGI struggle...

    Hi All,

    I am using Python and CGI to create a web server that displays charts from some data provided. Below is the code from two files. The first piece of code 'tries' to define a simple web-page, that is intended to contain an image that should be created by a script in the second file (call it a library file that knows how to plot different types of charts).

    The problem is on how to call the script located in the...
    See more | Go to post
No activity results to display
Show More
Working...