Witam,
Tworzę stronę logowania za pomocą: tej strony
Mam problem iż pokazuje mi się bład. Końcówka:
File "C:\Users\Mikołaj\Desktop\mysite\mysite\urls.py", line 25, in <module>
url(r'^login/$', 'django.contrib.auth.views.login'),
File "C:\Python36\lib\site-packages\django\conf\urls\__init__.py", line 85, in url
raise TypeError('view must be a callable or a list/tuple in the case of include().')
TypeError: view must be a callable or a list/tuple in the case of include().
25 linia urls.py:
url(r'^login/$', 'django.contrib.auth.views.login'),
Może tutaj trzeba dodać jakiś import bibliotek?
85 linia init.py:
def url(regex, view, kwargs=None, name=None):
if isinstance(view, (list, tuple)):
# For include(...) processing.
urlconf_module, app_name, namespace = view
return RegexURLResolver(regex, urlconf_module, kwargs, app_name=app_name, namespace=namespace)
elif callable(view):
return RegexURLPattern(regex, view, kwargs, name)
else:
raise TypeError('view must be a callable or a list/tuple in the case of include().') --> 85 linia
W czym problem?