Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #100908

CGI

From Pol Hallen <pythonml@fuckaround.org>
Newsgroups comp.lang.python
Subject CGI
Date 2015-12-26 10:41 +0100
Message-ID <mailman.31.1451231525.11925.python-list@python.org> (permalink)

Show all headers | View raw


Merry Christmas to all :-)

A (newbie) question: I'd like learn about CGI pyhton script to create 
some utility using http://localhost/python_script01.py

Something like that:

#!/usr/bin/python
print "Content-type: text/html"
print
print "<html>"
print "<center>Hello!</center>"
print "</html>"

How can I execute a local command (like ls or similar) and show output 
via browser?

I didn't find enough documentation to work with python and CGI :-/

Is python not good language to use it with CGI?

Thanks for help! :)

Pol

Back to comp.lang.python | Previous | NextNext in thread | Find similar | Unroll thread


Thread

CGI Pol Hallen <pythonml@fuckaround.org> - 2015-12-26 10:41 +0100
  Re: CGI Maitu Zentz <zen@nonirvana.org> - 2015-12-27 17:19 +0100
  Re: CGI Laurent Delacroix <laurent@krutt.org> - 2015-12-27 18:59 +0100
    Re: CGI Chris Warrick <kwpolska@gmail.com> - 2015-12-27 21:01 +0100

csiph-web