Jump to content

anirudh

Members
  • Posts

    4
  • Joined

  • Last visited

Posts posted by anirudh

  1. Ohh silly me, I forgot to add handler. Now I have put the following code in the .htaccess

     

      AddHandler mod_python .py
      PythonHandler mod_python.publisher
      PythonDebug On

     

    But still it is showing error 500 page. Is it because I dint reatart apache? If so how do i do it?

     

  2. How do you impliment mod_python in Heliohost? In the snake charmer page it is said that mod_python module in installed. Is there something to be done to apache? My script shows an error 500 page :huh: . I have set my chmod permission to 755 and put hashbang statement in the first line. Someone please help me. Apologies for my bad english.

     

    Page address : http://anirudh.ind.in/cgi-bin/test.py

     

    Page source code :

     

    #!/usr/bin/python
    from mod_python import apache
    def index(req):
            req.log_error('handler')
            req.content_type = 'text/html'
            req.send_http_header()
            req.write('Content-type: text/html\n')
            req.write('<html><head><title>test</title></head><body>')
            req.write('Hello World')
            req.write('</body></html>')
            return apache.OK

×
×
  • Create New...