time:2016 January 01 21:38:55
Description:
From today onwards I began to write my Django study notes, because there are too many cluttered articles on the web, not a system, there are too many training institutions to tell things too simple, no in-depth explanation Django, is a small note of their own it, The main reference is Django1.8 official documents, Address: www.djangoproject.com, opinion, big God do not spray!
Content:
Day one. First exploration of Django?
In the course of web development, we often encounter the problem of writing repetitive code, and Django's appearance solves the problem of repeating "making wheels", and Django was developed in a fast-paced newsroom, so it was designed to solve the web development framework faster and more efficiently.
How do we install Django?
Because the PC used by the author is basically OS X OS, this anthology is basically based on OS X production environment.
There are many ways to install Django, and the author uses a more concise and official default installation method, which is installed using the PIP management tool. "command:pip Install django==1.8.2"
Of course, when we were doing Django Web development, the older generation showed us a way to use the tool "virtualenv", one of the three great artifacts of Python. The advantage of using this tool is that we encounter a variety of development environment versions in our production environment, and we use virtualenv to solve the problem well. "command:pip Install virtualenv"
Create virtualenv directory, "command:virtualenv--no-site-packages project_folder" project_folder for the virtual environment directory you want to create
Activating Virtualenv,"command:source project_folder/bin/activate"
Exit virtualenv,"command:deactivate"
View the package files for the current virtual directory installation, "command:pip list"
Friendship Link:
Django Official website: https://www.djangoproject.com/
Django Learning Notes Day One