Python interface development: django

A: Installing django environment

If you already have pycharm environment, directly in the scripts files under python path, open cmd, execute the command: pip install django, you can install successfully.

 

II: New django project:

1. New project, select django, as shown below, fill out a path you want to store, as well as application name (write web) point directly create, you can create success

 

2. After the project is opened, generating the same directory structure as in FIG.


 

 

 3. How to run manage.py

a. A method as shown below, click to select the top right corner manage to run, you will see the results (http://127.0.0.1:8000 already started)

 

 

. B Another approach is: next to the path we django created, run cmd enter the command: python manage.py runserver 127.0.0.1:8000, can succeed

Open http://127.0.0.1:8000

 

Guess you like

Origin www.cnblogs.com/naibuma-blog/p/11263515.html