More complex
This commit is contained in:
parent
8ca9715ebd
commit
5251ec2639
|
@ -39,6 +39,7 @@ INSTALLED_APPS = [
|
|||
'django.contrib.staticfiles',
|
||||
'admin_extra_buttons',
|
||||
'tldtester.apps.TldtesterConfig',
|
||||
'tldtest',
|
||||
]
|
||||
|
||||
MIDDLEWARE = [
|
||||
|
@ -56,7 +57,7 @@ ROOT_URLCONF = 'tldtest.urls'
|
|||
TEMPLATES = [
|
||||
{
|
||||
'BACKEND': 'django.template.backends.django.DjangoTemplates',
|
||||
"DIRS": [],
|
||||
"DIRS": [BASE_DIR / "templates"],
|
||||
'APP_DIRS': True,
|
||||
'OPTIONS': {
|
||||
'context_processors': [
|
||||
|
|
12
tldtest/templates/base.html
Normal file
12
tldtest/templates/base.html
Normal file
|
@ -0,0 +1,12 @@
|
|||
{% load static %}
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>{% block title %}TLD Tester{% endblock %}</title>
|
||||
</head>
|
||||
<body>
|
||||
{% block content %}
|
||||
{% endblock content %}
|
||||
</body>
|
||||
</html>
|
|
@ -1,3 +1,4 @@
|
|||
{% extends "base.html" %}
|
||||
{% block content %}
|
||||
Hello World
|
||||
{% endblock content %}
|
|
@ -3,8 +3,10 @@ from django.views.generic import TemplateView
|
|||
|
||||
|
||||
class Index(TemplateView):
|
||||
template_name = 'index.html'
|
||||
template_name = 'home.html'
|
||||
|
||||
def home(request):
|
||||
return render(request, 'home.html')
|
||||
|
||||
"""
|
||||
def handler404(request):
|
||||
|
|
Loading…
Reference in a new issue