modpython, apache and windows

Discussion in 'Python' started by Sam, Jan 5, 2005.

  1. Sam

    Sam Guest

    Hi All,

    I am interested in learning python since I am hearing more and more
    about python for use in web development

    I am starting out on python, with knowledge of PHP some perl

    my current hurdle is setting up either apache 1 or 2 with python 2.3.3 I
    have installed modpython fine

    which informed me that I need to make some configuration changes to
    httpd.conf

    I have not had it working yet, searches on the web give conflicting
    suggestions and so far has confused me

    some forums mention spyce and serving .spy files

    so far I one explanation worked in that a .py file was parsed but I had
    to set the name of the actual file within apache.conf
    this seems strange

    thanks in advance >> SS


    --
    No virus found in this outgoing message.
    Checked by AVG Anti-Virus.
    Version: 7.0.298 / Virus Database: 265.6.7 - Release Date: 30/12/2004
     
    Sam, Jan 5, 2005
    #1
    1. Advertising

  2. Sam

    Steve Holden Guest

    Sam wrote:

    > Hi All,
    >
    > I am interested in learning python since I am hearing more and more
    > about python for use in web development
    >
    > I am starting out on python, with knowledge of PHP some perl
    >
    > my current hurdle is setting up either apache 1 or 2 with python 2.3.3 I
    > have installed modpython fine
    >
    > which informed me that I need to make some configuration changes to
    > httpd.conf
    >

    These changes are relatively easy, but of course making them requires
    access to the files, not always available unless you are managing your
    own server.

    Note, though, that it's easliy possible to use Python as a CGI language
    on most Apache installations.

    > I have not had it working yet, searches on the web give conflicting
    > suggestions and so far has confused me
    >

    Perhaps if you could explain what it is you are failing to do, you might
    eleicit some explicit help.

    > some forums mention spyce and serving .spy files
    >
    > so far I one explanation worked in that a .py file was parsed but I had
    > to set the name of the actual file within apache.conf
    > this seems strange
    >
    > thanks in advance >> SS
    >
    >

    Try creating a Python file (.py file, with world-executable permissions)
    in a cgi-bin directory:

    #!/usr/bin/env python
    print """Content-Type: text/plain

    Hello, world"""

    and see if you can call it from a web browser.

    regards
    Steve
    --
    Steve Holden http://www.holdenweb.com/
    Python Web Programming http://pydish.holdenweb.com/
    Holden Web LLC +1 703 861 4237 +1 800 494 3119
     
    Steve Holden, Jan 5, 2005
    #2
    1. Advertising

  3. Sam

    Steve Holden Guest

    Sam wrote:

    > Hi All,
    >
    > I am interested in learning python since I am hearing more and more
    > about python for use in web development
    >
    > I am starting out on python, with knowledge of PHP some perl
    >
    > my current hurdle is setting up either apache 1 or 2 with python 2.3.3 I
    > have installed modpython fine
    >
    > which informed me that I need to make some configuration changes to
    > httpd.conf
    >

    These changes are relatively easy, but of course making them requires
    access to the files, not always available unless you are managing your
    own server.

    Note, though, that it's easily possible to use Python as a CGI language
    on most Apache installations.

    > I have not had it working yet, searches on the web give conflicting
    > suggestions and so far has confused me
    >

    Perhaps if you could explain what it is you are failing to do, you might
    elicit some explicit help.

    > some forums mention spyce and serving .spy files
    >
    > so far I one explanation worked in that a .py file was parsed but I had
    > to set the name of the actual file within apache.conf
    > this seems strange
    >
    > thanks in advance >> SS
    >
    >

    Try creating a Python file (.py file, with world-executable permissions)
    in a cgi-bin directory:

    #!/usr/bin/env python
    print """Content-Type: text/plain

    Hello, world"""

    and see if you can call it from a web browser.

    regards
    Steve
    --
    Steve Holden http://www.holdenweb.com/
    Python Web Programming http://pydish.holdenweb.com/
    Holden Web LLC +1 703 861 4237 +1 800 494 3119
     
    Steve Holden, Jan 5, 2005
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?iso-8859-1?q?Lorenz_K=F6hl?=

    modpython compilation error

    =?iso-8859-1?q?Lorenz_K=F6hl?=, Aug 29, 2003, in forum: Python
    Replies:
    0
    Views:
    359
    =?iso-8859-1?q?Lorenz_K=F6hl?=
    Aug 29, 2003
  2. Julio C?sar Carrascal

    ModPython and embedding

    Julio C?sar Carrascal, Nov 13, 2003, in forum: Python
    Replies:
    0
    Views:
    290
    Julio C?sar Carrascal
    Nov 13, 2003
  3. Bob Van Zant

    Re: modpython, apache and windows

    Bob Van Zant, Jan 5, 2005, in forum: Python
    Replies:
    1
    Views:
    343
  4. Wensheng

    egg and modpython

    Wensheng, Sep 8, 2006, in forum: Python
    Replies:
    8
    Views:
    439
    Paul Boddie
    Sep 13, 2006
  5. Andrus
    Replies:
    0
    Views:
    224
    Andrus
    Jun 18, 2008
Loading...

Share This Page