Re: URLconf problem: why I'm geting 404 error when I should'nt?

2016-08-23 Thread Lao Zzi
read the django tutorial first. There is good django tutorial on the official site and also there is "django girls" tutorial on the internet. Both of them is good. Django doesn't see your urlconf. See at error, django find only ^admin/ regex. Your regex is not finded, so you have to edit you urls.p

Re: urlconf problem

2014-08-06 Thread Joel Goldstick
On Wed, Aug 6, 2014 at 8:22 AM, Collin Anderson wrote: > shouldn't it be: > > urlpatterns = patterns('', > ) > Thanks for catching that! As it ended up, the problem was in the blog_app view code. When I ported from earlier version I had to edit some things, and I had bad code in the view that ne

Re: urlconf problem

2014-08-06 Thread Collin Anderson
shouldn't it be: urlpatterns = patterns('', ) And blog_app/__init__.py and blog_app/urls.py exist? Could you include a longer traceback? -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails

Re: urlconf problem

2014-08-06 Thread Erik Cederstrand
Den 06/08/2014 kl. 01.00 skrev Joel Goldstick : > I have this: > > from django.conf.urls import patterns, include, url > > from django.contrib import admin, admindocs > import blog_app > > admin.autodiscover() > > patterns = patterns('', >url(r'^admin/doc/', include(admindocs.urls)), >

Re: urlconf problem

2014-08-05 Thread Joel Goldstick
what's strange to me is that I can comment out each of the urls and I get basically the same error message. When all three are gone, it complains there are no urls. But I'm stuck on thinking I have a type. background: this was a 1.3 project that I converted to 1.6 today using virtualenv to keep

Re: urlconf problem

2014-08-05 Thread Lachlan Musicman
Bugger - I find that error when left out of the settings or the wsgi points to the wrong settings file. Usually when I'm swapping between envs "settings.dev" "settings.prod" L. On 6 August 2014 09:44, Joel Goldstick wrote: > On Tue, Aug 5, 2014 at 7:15 PM, Lachlan Musicman wrote: >> Make sure t

Re: urlconf problem

2014-08-05 Thread Joel Goldstick
On Tue, Aug 5, 2014 at 7:15 PM, Lachlan Musicman wrote: > Make sure the blog_app is in your settings.py? It is: INSTALLED_APPS = ( 'django.contrib.admin', 'django.contrib.admindocs', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.c

Re: urlconf problem

2014-08-05 Thread Lachlan Musicman
Make sure the blog_app is in your settings.py? On 6 August 2014 09:00, Joel Goldstick wrote: > I have this: > > from django.conf.urls import patterns, include, url > > from django.contrib import admin, admindocs > import blog_app > > admin.autodiscover() > > patterns = patterns('', > url(r'^a

Re: UrlConf problem when capture value from url

2012-04-20 Thread DanYun Liu
yes, it works well :) On Fri, Apr 20, 2012 at 10:11 PM, Daniel Sokolowski < daniel.sokolow...@klinsight.com> wrote: > Yes {{STATIC_URL}} - > https://docs.djangoproject.com/en/dev/howto/static-files/#using-django-contrib-staticfiles > > > > Does that help? > *From:* DanYun Liu > *Sent:* Frid

Re: UrlConf problem when capture value from url

2012-04-20 Thread Daniel Sokolowski
Yes {{STATIC_URL}} - https://docs.djangoproject.com/en/dev/howto/static-files/#using-django-contrib-staticfiles Does that help? From: DanYun Liu Sent: Friday, April 20, 2012 8:57 AM To: django-users@googlegroups.com Subject: UrlConf problem when capture value from url When I use url pattern

Re: URLConf

2010-06-16 Thread Rolando Espinoza La Fuente
On Wed, Jun 16, 2010 at 11:48 PM, Siddharth. S wrote: > Hi, > > I did the following to allow the page to be loaded with or without the > '/' at the end: > > (r'^mysite(/*)$', redirect_to, {'url':'/mysite/home/'}), > > in URL patterns. I got an error page, and the following error: > > Exception Typ

Re: urlconf {{ app }}/{{ view }}

2009-04-24 Thread Alex Gaynor
On Fri, Apr 24, 2009 at 10:18 AM, Thierry wrote: > > what if u want to have an urlconf as such > /{{ app }}/{{ view }}/ > > so without specifying the view, it will dynamically load the app with > the variable input and the view...? > > > No, django doesn't enforce any type of convention on the typ

Re: Urlconf page not found question

2008-10-26 Thread Steve Holden
David Rodrigues wrote: > Or if you have ^accounts in parent urls.py file, then perhaps the '$' > at the end of the ^login/$ expression is problematic, as the dollar > sign represents the end of a line, I believe. > It's fairly obvious that the listing of the URLconfs is from the 404 output of

Re: Urlconf page not found question

2008-10-26 Thread David Rodrigues
Or if you have ^accounts in parent urls.py file, then perhaps the '$' at the end of the ^login/$ expression is problematic, as the dollar sign represents the end of a line, I believe. On Oct 26, 2008, at 10:02 AM, Daniel Roseman wrote: > > On Oct 26, 1:23 pm, ehpmail <[EMAIL PROTECTED]> wrot

Re: Urlconf page not found question

2008-10-26 Thread Daniel Roseman
On Oct 26, 1:23 pm, ehpmail <[EMAIL PROTECTED]> wrote: > My URLconf has the following urls: > >    1.  ^admin/(.*) >    2. ^$ >    3. ^popular/$ >    4. ^user/(\w+)/$ >    5. ^tag/([^s]+)/$ >    6. ^tag/$ >    7. ^search/$ >    8. bookmark/(\d+)/$ >    9. ^login/$ >   10. ^logout/$ >   11. ^regist

Re: URLconf and style.css

2008-06-14 Thread Karen Tracey
On Sat, Jun 14, 2008 at 2:41 PM, LB <[EMAIL PROTECTED]> wrote: > >Hi, > > I've just finished my first template, it seems to work finie, but is > not properly displayed. > Indeed, the stylesheet seems not to be transmitted to firefox. > > When I look at the output of django web server, I can se

Re: URLConf/ManytoManyField issue (exercise problem from Teach Yourself Django in 24 Hour)

2008-03-09 Thread Evert
> I can do that, but then I get a key error with the name. However, it   > works with similar code here: > > def details(request, pID='0', opts=()): > response = HttpResponse() >         response.write("\n") >         try: >                 p = Person.objects.get(id=pID) >                 if (pID

Re: URLConf/ManytoManyField issue (exercise problem from Teach Yourself Django in 24 Hour)

2008-03-08 Thread Rilindo Foster
Oh yeah, SQL output: [EMAIL PROTECTED]:~/iFriends$ python manage.py sql People BEGIN; CREATE TABLE "People_blog" ( "id" serial NOT NULL PRIMARY KEY, "title" varchar(200) NOT NULL, "text" text NOT NULL ); CREATE TABLE "People_person" ( "id" serial NOT NULL PRIMARY KEY, "use

Re: URLConf/ManytoManyField issue (exercise problem from Teach Yourself Django in 24 Hour)

2008-03-08 Thread Rilindo Foster
On Mar 8, 2008, at 7:04 AM, Evert Rol wrote: > > Have you checked what 'd' is here? It may be something different than > you'd expect or hope, in particular for the __dict__[d] lookup (not > sure what you're expecting here). > I would actually work with something like > Person.objects.filter(id=pI

Re: URLConf/ManytoManyField issue (exercise problem from Teach Yourself Django in 24 Hour)

2008-03-08 Thread Evert Rol
> I am going Django (liking it so far), and I seem to hit a wall with > one of the exercises. It likely because of my unfamiliarity with > Python, so bear with me, please. > > At the end of Hour 6, I got two exercises to do: > > 1. Create an additional view for the People object that displays

Re: URLconf: Invalid syntax when using naming URL patterns

2007-12-13 Thread sector119
Thank you! I miss "url" at the beginning of all patterns :) On 13 Грд, 17:14, "Marty Alchin" <[EMAIL PROTECTED]> wrote: > On Dec 13, 2007 9:58 AM, sector119 <[EMAIL PROTECTED]> wrote: > > > urlpatterns = patterns('django.views.generic', > > (r'^location/$', 'list_detail.object_list', location

Re: URLconf: Invalid syntax when using naming URL patterns

2007-12-13 Thread Marty Alchin
On Dec 13, 2007 9:58 AM, sector119 <[EMAIL PROTECTED]> wrote: > urlpatterns = patterns('django.views.generic', > (r'^location/$', 'list_detail.object_list', location_list_info, > name='locations-location_list'), > ) In order to name your URLpatterns, you'll need to use the url() function. ur

Re: URLconf: Invalid syntax when using naming URL patterns

2007-12-13 Thread yml
Hello, I don't know what line is 13 but it seems to me that for the second urlpatterns should be: """ urlpatterns += patterns( """ Let me know if this help. On 13 déc, 15:58, sector119 <[EMAIL PROTECTED]> wrote: > Hi all! > > When I try to use Naming URL patterns I get error: > Exception Type:

Re: URLconf: Invalid syntax when using naming URL patterns

2007-12-13 Thread sector119
I use django current trunk, if this info is needed. On 13 Грд, 16:58, sector119 <[EMAIL PROTECTED]> wrote: > Hi all! > > When I try to use Naming URL patterns I get error: > Exception Type: ImproperlyConfigured > Exception Value:Error while importing URLconf 'locations.urls': > in

Re: urlconf for multiple page slugs

2007-08-10 Thread Peter Baumgartner
> > > Collin's suggestion may sound daunting, but it's really quite easy: Thanks guys. I took your advice. Here is my solution: http://www.djangosnippets.org/snippets/362/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Gro

Re: urlconf for multiple page slugs

2007-08-10 Thread Tim Chase
> About the only way to do that is just grab (.*) from the url, and > parse it in your view, looking up slugs as needed Collin's suggestion may sound daunting, but it's really quite easy: your urls.py can have something like r"^(?P(?:[-\w]+/)*[-\w]+)/?$" and then in your view: def my_view(re

Re: urlconf for multiple page slugs

2007-08-10 Thread Collin Grady
About the only way to do that is just grab (.*) from the url, and parse it in your view, looking up slugs as needed --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send e