-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
기본 세팅: settings에 app 등록, index.html 생성, 이와 관련된 url, view 추가
- Loading branch information
Showing
13 changed files
with
6 additions
and
15 deletions.
There are no files selected for viewing
Binary file added
BIN
+193 Bytes
codelion/django/blogproject/blogapp/__pycache__/__init__.cpython-39.pyc
Binary file not shown.
Binary file added
BIN
+234 Bytes
codelion/django/blogproject/blogapp/__pycache__/admin.cpython-39.pyc
Binary file not shown.
Binary file added
BIN
+472 Bytes
codelion/django/blogproject/blogapp/__pycache__/apps.cpython-39.pyc
Binary file not shown.
Binary file added
BIN
+231 Bytes
codelion/django/blogproject/blogapp/__pycache__/models.cpython-39.pyc
Binary file not shown.
Binary file added
BIN
+368 Bytes
codelion/django/blogproject/blogapp/__pycache__/views.cpython-39.pyc
Binary file not shown.
Binary file added
BIN
+204 Bytes
codelion/django/blogproject/blogapp/migrations/__pycache__/__init__.cpython-39.pyc
Binary file not shown.
1 change: 1 addition & 0 deletions
1
codelion/django/blogproject/blogapp/templates/blogapp/index.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<h1>안녕하세요.</h1> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
from django.shortcuts import render | ||
|
||
# Create your views here. | ||
def home(request): | ||
return render(request, 'blogapp/index.html') |
Binary file modified
BIN
+9 Bytes
(100%)
codelion/django/blogproject/blogproject/__pycache__/settings.cpython-39.pyc
Binary file not shown.
Binary file modified
BIN
-574 Bytes
(41%)
codelion/django/blogproject/blogproject/__pycache__/urls.cpython-39.pyc
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,8 @@ | ||
"""blogproject URL Configuration | ||
The `urlpatterns` list routes URLs to views. For more information please see: | ||
https://docs.djangoproject.com/en/4.0/topics/http/urls/ | ||
Examples: | ||
Function views | ||
1. Add an import: from my_app import views | ||
2. Add a URL to urlpatterns: path('', views.home, name='home') | ||
Class-based views | ||
1. Add an import: from other_app.views import Home | ||
2. Add a URL to urlpatterns: path('', Home.as_view(), name='home') | ||
Including another URLconf | ||
1. Import the include() function: from django.urls import include, path | ||
2. Add a URL to urlpatterns: path('blog/', include('blog.urls')) | ||
""" | ||
from django.contrib import admin | ||
from django.urls import path | ||
from blogapp import views | ||
|
||
urlpatterns = [ | ||
path('admin/', admin.site.urls), | ||
path('', views.home, name='home'), | ||
] |
Binary file not shown.