Hi! I have little trouble with reverse function in Django. When I run my
project as ./manage runserver, everything is just fine - reverse gives me
url in /page/xxx format. When I run it as apache2 instance using this conf
file:
Listen 8001
<VirtualHost *:8001>
ServerName project.tld
DocumentRoot "/var/www/project"
ErrorLog /var/www/project/error.log
CustomLog /var/www/project/access.log combined
<Directory "/var/www/project/">
SetHandler python-program
PythonHandler django.core.handlers.modpython
SetEnv DJANGO_SETTINGS_MODULE settings
PythonOption django.root /var/www/project
PythonDebug Off
PythonPath
"['/var/www/','/var/www/project','/usr/local/lib/site-packages/django']
+ sys.path"
</Directory>
</VirtualHost>
reverse function returns url including server path -
/var/www/project/page/xxx. It means, reverse returns url in this format:
http://project.tld/var/www/project/page/xxx. What is interesting,
http://project.tld/var/www/project/page/xxx and
http://project.tld/page/xxx gives me same results, but reverse() returns
url with "ugly" server path.
Any suggestions how can I fix it?
Thanks,
Jirka
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.