[Answer]-How can django view access url pattern?

1👍

Yes, you can get it from the request.META object.

referer = request.META.get('HTTP_REFERER')

Alternatively, you can resolve the URL using reverse() method

from django.core.urlresolvers import reverse

url = reverse('basic')

Leave a comment