Hi.
I share a server with other people where we usually develop php
applications. I like to program in Python and I wanted to start usind
Django so today I tried to install and configure it. It seems I
succeded, because if I put this in the httpd.conf file it display the
"Django is working" page.

<Location "/">
    SetHandler python-program
    PythonHandler django.core.handlers.modpython
    SetEnv DJANGO_SETTINGS_MODULE mydjangosite.settings
    PythonOption django.root /mydjangosite
    PythonDebug On
    PythonPath "['/home/carlo/public_html/mydjangosite'] + sys.path"
</Location>

The problem is that I can't set Location to "/", because everything
else (i.e. php) will stop to work as usual. So what I'd like to do is
to set location to a specific location, but I don't know how. I tried
different things, but nothing worked.

When I installed mod_python I tried this:

#<Directory /home/carlo/public_html/mydjangosite>
#       AddHandler mod_python .py
#       PythonHandler mptest
#       PythonDebug On
#</Directory>

And it worked. If I uncomment these lines, for every .py file I point
the browser to it runs mptest and shows the "Hello world" message.

So I think it should be just a problem of setting the right paths, I hope.

My setup is this:

My home directory: /home/carlo
sites directory: /home/carlo/public_html  <--- here I have other
directories, one for each php site
django site directory: /home/carlo/public_html/mydjangosite <--- here
is where settings.py, manage.py and so on are located

What shall I put in the httpd.conf?

Thanks for your help,
Carlo

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to