FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


Server 4 not supports Python?





chiconguyen
Perhaps, the server 4 does not support Python, how to run Python files? Please help me!
Bondings
You should be able to run Python scripts as cgi or preferrably as mod_wsgi (faster).

http://code.google.com/p/modwsgi/

Example: http://modpython.frihost.org/mod_wsgi.py

mod_wsgi.py
Code:
def application(environ, start_response):
    status = '200 OK'
    output = 'Hello World!'

    response_headers = [('Content-type', 'text/plain'),
                        ('Content-Length', str(len(output)))]
    start_response(status, response_headers)

    return [output]


.htaccess file in the directory of mod_wsgi.py (assumes there is an index.py file using mod_wsgi for the directory index)
Code:
Options ExecCGI

AddHandler cgi-script .cgi
AddHandler wsgi-script .wsgi
AddHandler wsgi-script .py

DirectoryIndex index.py


Most big Python applications support mod_wsgi, at least from what I heard. Eg. Django: http://code.google.com/p/modwsgi/wiki/IntegrationWithDjango and https://code.djangoproject.com/wiki/django_apache_and_mod_wsgi (not tried though)
chiconguyen
Currently, I did a web project using django framework for the implementation.
So I want to check on frihost.
Mod can help me config to run django project? Please!
Bondings
chiconguyen wrote:
Currently, I did a web project using django framework for the implementation.
So I want to check on frihost.
Mod can help me config to run django project? Please!

Did you read and try out the instructions on the links I posted? http://code.google.com/p/modwsgi/wiki/IntegrationWithDjango and https://code.djangoproject.com/wiki/django_apache_and_mod_wsgi

If you encounter a specific problem or error, I can definitely try to help you. However I won't install it for you.
Related topics
Python - Django Framework in server 4?
Up and running in server 4
Server 4 problems (17-20-01-2012)
Mod_python not working on server 4
Server 4 opened for new accounts
php not on?
mod_python server 4
server 4 - down for at least a week
time on server 4
server 4 down?
server 4 - down
SMTP on Server 4?
[Server 4] Mod_python
Mysql Down on Server 4
Reply to topic    Frihost Forum Index -> Support and Web Hosting -> Web Hosting Support

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.