code_junkie

How to access to the root path in a mod_python directory?

Nov 13th, 2011
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. <Directory /var/www/MYDOMAIN.com/htdocs>
  2. SetHandler mod_python
  3. PythonHandler mod_python.publisher
  4. PythonDebug On
  5. </Directory>
  6.  
  7. from mod_python import apache
  8.  
  9. def requesthandler(req):
  10. req.content_type = "text/plain"
  11. req.write("Hello World!")
  12. return apache.OK
  13.  
  14. DirectoryIndex index
Add Comment
Please, Sign In to add comment