could python serve web scripts ?

dsavitsk dsavitsk at e-coli.net
Fri Nov 1 01:14:20 EST 2002


"black" <blackprogramming at yahoo.com> wrote in message
news:mailman.1036123142.8986.python-list at python.org...
Howdy~
  I'm learning ASP these days and bothered VBScript much, I want to kick it
off and I wonder if Python could be substitution. and what about other
scripts if not, thanx~

you can use Python for active server pages.  here's an example how ...

#-------------------------------
<%@ Language=Python %>
<%
def get_version():
    return '0.1'
%>

<HTML>
My Python ASP Script, version
<%
Response.Write(get_version())
%>
</HTML>
#--------------------------------

There are many weird things, and things that won't work though (like *.pth
files in your path), so it is worth searching google groups to get a feel
for them.  It is also worth looking into other servers like apache +
mod_python or medusa or plenty of others which deal with python a little
better.  Really you should only use iis + Python if you have no choice about
using iis.  Really you should only use iis if you have no choice about using
iis.

-d





More information about the Python-list mailing list