django yes web Application framework
Internet delivery data Information Power grid delivery electric
power plant -----》 Server program (Nginx、apache) Web Application essence — Program — Server program + Applications
Applications — Electrical appliances
WSGI---- Power module
Web frame
Web application — Make electrical appliances
Web frame — The basic principle
\1. There are different brands of electrical appliances ,web So is the framework
Django Omnipotent web frame
Web.py Compact web frame
Flask.py A lightweight excellent web frame
Tornado An asynchronous web frame
-m :models Model : Responsible for business data objects and database objects
-t : template Templates : Responsible for showing the page to users (html)
-v :view View : Bridge between model and formwork
-m :models Model : Responsible for business data objects and database objects
-v : view View : Pages that interact with users
-c : controller controller : Receive user input , Call the model and view to complete the user's request , A bridge between models and views
``
#### 3、 ... and 、 Environment building
1) View the current virtual environments Workon
2) Creating a virtual environment mkvirtualenv -p /usr/bin/python3 djangoApp
3) Exit virtual environment :deactivate
4) Delete virtual environment :rmvirtualenv djangoApp
1.mkvirtualenv -p /usr/bin/python3 djangoApp
2.pip install django==2.1.7
3.Cd The name of the folder where the project file is stored
4. Choose a generic way to create a project independent of the editor version ----》 command django-admin startproject ( Project name )
5.python manage.py runserver 0.0.0.0:8000
1) To configure
1.pycharm Create a new empty project locally
2. Configure remote interpreter ( Be careful : Consistent with the project interpreter )
3. Modify the file mapping path
4. Set up automatic synchronization