Chinese interpretation of settings in django

APP_DIRSWhether to find the file in the App.
BACKENDDefine the template engine to identify the variables and instructions in the template. The built-in templates include Django Templates and jinja2. Jinja2
DIRSsets the path of the template and tells Django to find the location of the template in that place. The default is an empty table column
OPTIONSThe calling function used to fill the context in the RequestContext, generally without any modification.
STATIC_URLIt is a required attribute and the attribute value cannot be empty. If STATICFILES_DIRS is not configured, STATIC_URL can only identify the
STATICFILES_DIRSconfigurable attributes of the static resource folder in the app. The attribute is in the form of a list or tuple, and each list element represents a static resource file. Folders, these folders can be named by themselves
adminBuilt-in background management system
authBuilt-in user authentication system
contenttypesRecord all model metadata in the project (Django's ORM framework)
sessions sessionsession function, used to identify the current user identity, record related user information
messagesMessage prompt function to
staticfilesfind static Resource path
BASE_DIRProject path: The specific path of the current project in the system is mainly read through the OS module. The code is automatically generated when the project is created. Under normal circumstances, there is no need to modify the
SECRET_KEYkey configuration: it is a random value, which is automatically generated when the project is created. Under normal circumstances, no modification is required.
DEBUGDebugging mode
ALLOWED_HOSTSDomain name access authority
INSTALLED_APPS APPlist
"Security Middleware"Built-in security mechanism to protect the communication security between users and websites
SessionMiddlewareSession function
LocaleMiddlewareSupport Chinese language
CommonMiddlewareProcessing request information, standardizing request content
CsrfViewMiddlewareTurn on CSRF protection function
Authentication MiddlewareTurn on built-in user authentication system
MessageMiddlewareTurn on the built-in information prompt function.
XFrameOptions MiddlewarePrevent malicious programs from clicking and hijacking.
URL"URL (Uniform Resource Locator, uniform resource locator) is available from the Internet
succinct representation of a resource location and access method, the standard is the address of a resource on the Internet, on the Internet each
file has a unique The URL is used to indicate the path location of the file. Simply put, the URL is
the web address that is often referred to . Each address represents a different web page. In Django, the URL is also called URLconf"

Guess you like

Origin blog.csdn.net/weixin_47021806/article/details/111351620
Recommended