I'm not really a pro with the who path stuff but this is how I see it.
ROOT_URLCONF = 'projectname.urls'
In my project I can import projectname and projectname.urls.
generally all django project have a __init__.py file which makes it a
module, so in your case soco-site should be a valid module wi
On Apr 3, 4:58 pm, Shawn Milochik wrote:
> In short, it has to be on your PYTHONPATH or in the local directory.
OK, then I'm still not getting how this works. The full path to my
setting and urls files are:
/Users/roy/s7/soco/soco-site/settings.py
/Users/roy/s7/soco/soco-site/urls.py
If I have
In short, it has to be on your PYTHONPATH or in the local directory.
If you're importing from the local directory it always works (assuming
the subdirectory contains a file named __init__.py). The other path,
'foo.urls' works because 'foo' is in your PYTHONPATH.
Do whatever makes sense to you and
On Apr 3, 2:55 pm, andy wrote:
> Well I'm guess you don't have to. Both ROOT_URLCONF = "foo.urls" and
> ROOT_URLCONF = "urls" seem to work fine.
Interesting, I just tried it that way, and sure enough it does work.
I had simply been following the examples in the tutorial, which showed
the foo.urls
Well I'm guess you don't have to. Both ROOT_URLCONF = "foo.urls" and
ROOT_URLCONF = "urls" seem to work fine.
On Apr 3, 8:11 am, Roy Smith wrote:
> I don't understand how ROOT_URLCONF is declared in settings.py. If I
> put all my apps (and my settings.py file) in a directory "foo", I'm
> suppose
I don't understand how ROOT_URLCONF is declared in settings.py. If I
put all my apps (and my settings.py file) in a directory "foo", I'm
supposed to do:
ROOT_URLCONF = "foo.urls"
This seems counter-intuitive to me. When I run my app (by running
"python manage.py runserver"), I'm already in the
6 matches
Mail list logo