I have a problem with Django url patterns.
When I add '/' to the end of the index URL, the page returns 404 error (Page not found), and if I remove '/' from the end of the URL, the page will work fine.
The problem is not reproducing with the url for the admin page, can someone explain what is happening?
urlpatterns = [
url(r'^admin/', admin.site.urls),
url(r'^$/',index),
]
source
share