Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#10081 closed (duplicate)

In tutorial 3, url decoupling is incomplete

Reported by:… Owned by: nobody
Component: Documentation Version: 1.0
Severity: Keywords: tutorial 3 urls routes
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:


in tutorial 3, the last mention of polls/ still references the site in wich it's installed, missing the point on decoupling:

urlpatterns = patterns('mysite.polls.views',
    (r'^$', 'index'),
    (r'^(?P<poll_id>\d+)/$', 'detail'),
    (r'^(?P<poll_id>\d+)/results/$', 'results'),
    (r'^(?P<poll_id>\d+)/vote/$', 'vote'),

Should be:

urlpatterns = patterns('polls.views',
    (r'^$', 'index'),
    (r'^(?P<poll_id>\d+)/$', 'detail'),
    (r'^(?P<poll_id>\d+)/results/$', 'results'),
    (r'^(?P<poll_id>\d+)/vote/$', 'vote'),

I'm a complete newbie but that makes more sense to me (and it works).

Change History (2)

comment:1 Changed 7 years ago by programmerq

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #9860

comment:2 Changed 7 years ago by ubernostrum

(and seeing as this was a duplicate of no less than six other tickets, it's time once again to ask that people please search the tracker before opening new tickets)

Note: See TracTickets for help on using tickets.
Back to Top