Setting up Django in apache

0 views
Skip to first unread message

Pepsi330ml

unread,
Sep 3, 2008, 10:39:26 PM9/3/08
to Django users
Hi,

Initially, my setting in apache is

<Location "/">
...
</Location>

The web request http://www.mydjango.com will be handle by my django
page.

Now, i want to change the web request to http://www.mydjango.com/pepsi,
to be handled by my django page.
I do not want to change the urls.py in my django project.

This do not work.
<Location "/pepsi/">
...
</Location


How do i configure the apache to support this?

Thank you.

Pepsi330ml

unread,
Sep 3, 2008, 11:28:47 PM9/3/08
to Django users
Hi

Forget to add on. I am using Django version 0.96.
Don't intend to upgrade to version 1.0 now.

Thus i cannot use the PythonOption django.root
Is there other alternative?

Thank you.

Graham Dumpleton

unread,
Sep 4, 2008, 12:04:03 AM9/4/08
to Django users
From memory the answer is 'No'.

Graham

James Bennett

unread,
Sep 4, 2008, 12:10:44 AM9/4/08
to django...@googlegroups.com
On Wed, Sep 3, 2008 at 10:28 PM, Pepsi330ml <pepsi...@gmail.com> wrote:
> Thus i cannot use the PythonOption django.root
> Is there other alternative?

Well, what you can generally do to work around this if you have an
older Django is to create a new file, say, root_urls.py in your
project, and set it up like a normal URLConf, but in it put only a
single pattern:

(r'^your_site_root/', include('your_real_urls.py'),

Then make this your root URLConf.


--
"Bureaucrat Conrad, you are technically correct -- the best kind of correct."

Reply all
Reply to author
Forward
0 new messages