from django.http import HttpResponse
from django.shortcuts import render
def post_home(request):
return HttpResponse("<h1>Hi</h1>")
from django.conf.urls import include, url
from django.contrib import admin
urlpatterns = [
url(r'^admin/', admin.site.urls),
url(r'^posts/$', "НАДО СУДА ПЕРЕДАТЬ ФУНКЦИЮ"),
]
url(r'', include('posts.urls',namespace='posts'))
from django.conf.urls import url
from . import views
urlpatterns = [
url(r'^post/$', views.post_home, name='post'),
]