CGI module does not parse data

Mardy mardy at users.sourceforge.net
Sun Dec 4 14:46:28 EST 2005


Le die Fri, 02 Dec 2005 12:18:28 -0800, amfr ha scribite:
> import cgi
> form = cgi.FieldStorage()
> print form["test"]
> print "test"
> 
> I would only be able to see "test", not "hello world"
> I am sure its not my browser

As Tim said, you have tu use "form['test'].value", because "print
form['test']" will make pythoun output something like this:
<form object at ....>
and your browser won't show it, mistaking it as an HTML tag.


-- 
Saluti,
    Mardy
http://interlingua.altervista.org




More information about the Python-list mailing list