Django Installation

Installing of Django (

Step1: Install first python in your system and set the python path

Step2:Start run command and type cmd and press enter.

Step3:After opening the command dialog box type of the following command.(make sure that your internet of their PC should be on)

pip install django(for latest version)
pip install django==xyz(xyz is stands for any specific version)

BASIC CODE


Step 4:

After successfully installation check your django version by type following command, pyth

Let’s Start with Basic code

pip install django This code used for installing django in Windows
pip install django==version This code used for install django for specific version
python -m django –version This code used for checking the version of django
django-admin startproject projectname This code used for creating the project
python manage.py startapp appname This code used for create app in under project
python manage.py makemigrations This code used Create the migrations (generate the SQL commands).
python manage.py migrate This code used migrations (execute the SQL commands)
python manage.py createsuperuser This code used for given the password to the project
python manage.py runserver This code used for run your project(8000 by default port address)
python manage.py runserver 8080(specific) This code used for run project in specific port address
Subscribe Now