python - the requested URL was not found on this server django -
I'm following a YouTube tutorial, and getting an error ...
An error occurred
The requested URL / Hello was not found on this server site / urls.py
Urlpatterns = pattern ('', url (r '^ hello / $', article.views.hello), ...) article / views.py
< Import from django.shortcuts from pre> submit django.http import from HttpResponse def hello (request): name = 'mike' html = '& lt; Html & gt; & Lt; Body & gt; Sup% s & lt; / Body & gt; & Lt; / Html & gt; '% Name return HttpRequest (html) site / settings.py
INSTALLED_APPS = (...' article ',)< / Url/ Hellohas no trailing slash (/). You/optionally?:url (r '^ hello /? $', Can you create a URL pattern match by adding articles? Views.hello),
Comments
Post a Comment