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  / Hello  has no trailing slash (   / ). You  /  optionally ? : 

  url (r '^ hello /? $', Can you create a URL pattern match by adding articles? Views.hello),  

Comments

Popular posts from this blog

c# - SignalR: "Protocol error: Unknown transport." when navigating to hub -

class - Kivy: how to instantiate a dynamic classes in python -

java - Algorithm negotiation fail SSH in Jenkins -