On Mon, 09 Nov 2009 10:36:31 -0800, Victor Subervi <victorsube...@gmail.com> wrote:

Of course. Let me start with some updates to httpd.conf, which didn't help
anyway:

<VirtualHost *:80>
ServerAdmin m...@creative.vi
DocumentRoot /var/www/html/angrynates.com
ServerName angrynates.com
Options +ExecCGI -IncludesNoExec
<Directory /var/www/html/angrynates.com/global_solutions>
 Options +ExecCGI
 AllowOverride All
 AllowOverride FileInfo
 #AddHandler mod_python .py
 #PythonHandler mod_python.publisher
 #PythonDebug On
AddHandler cgi-script .cgi .py
Options Includes Indexes SymLinksIfOwnerMatch ExecCGI
<IfModule mod_security.c>
 SecFilterEngine Off
</IfModule>
<IfModule mod_security2.c>
 SecRuleEngine Off
</IfModule>
AddHandler cgi-script .cgi .py
Options Includes Indexes SymLinksIfOwnerMatch ExecCGI

<IfModule mod_security.c>
 SecFilterEngine Off
</IfModule>
<IfModule mod_security2.c>
 SecRuleEngine Off
</IfModule>

</Directory>
</VirtualHost>

Here's index.py:

#!/usr/bin/python

import string
import cgitb; cgitb.enable()
import cgi
import sys,os
sys.path.append(os.getcwd())
from template import template

ourFile = string.split(__file__, "/")
page = ourFile[len(ourFile) - 1][:-3]

form = cgi.FieldStorage()
w = form.getfirst('w', '1024')

template(page, w)



Can you try running index.py from the command-line, and let me know if that works?

Also, as you've already been asked - please start your replies *below* the text you are replying to. Putting your replies above the last email, or "top-posting" makes reading long email threads with lots of text distracting and frustrating.



--
Rami Chowdhury
"Never attribute to malice that which can be attributed to stupidity" -- Hanlon's Razor
408-597-7068 (US) / 07875-841-046 (UK) / 0189-245544 (BD)
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to