[Answered ]-Django1.8 to have regular expression for url in url.py

2👍

You are missing the named capturing group for the uri:

url(r'^subcategory/new/(?P<pk>\d+)/(?P<uri>\S+)/$',item.views.subcategory_new, name="subcategory_new"),

And, I’ve also replaced \s+ with \S+ since I doubt you actuall want to capture one or more space characters.

👤alecxe

Leave a comment