mod_python and file not found

Hello, I'm trying to configure the apache to handle the python scripts. My
platform is a CentOs server.
I wrote these directives in the conf.d/python.conf:
<Directory /var/www/html/my/dir>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
AddHandler mod_python .py
PythonHandler mod_python.publisher
PythonDebug On
</Directory>

The results are that if the script writes something on the server it works
fine but if the script contains only html like this:
print "Content-type: text/html\n"
print "<html>"
print "<body>"
print "<p>ok</p>"
print "</body>"
print "</html>"

it returns url not found on this server. It seems that I can't send info
back to the browser.

Share This Page

Welcome to The Coding Forums!

Welcome to the Coding Forums, the place to chat about anything related to programming and coding languages.

Please join our friendly community by clicking the button below - it only takes a few seconds and is totally free. You'll be able to ask questions about coding or chat with the community and help others.
Sign up now!