[Django]-Pass a variable ( a flag ) from urls.py to views.py in django

7👍

You can send a flag from the urlconf to the view by using the optional third parameter:

url(r'^alumni/(?P<blog_author>[^/]+)/$', 'entries', {'alumni': True}, name='blog'),

Leave a comment