/dj1

Description::Django is a Python-based free and open-source web framework, which follows the model-view-template architectural pattern. It is maintained by the Django Software Foundation, an independent organization established as a 501 non-profit. Django's primary goal is to ease the creation of complex, database-driven websites.

Primary LanguagePython

Documentation

view on github page here

Before install django make sure you have installed latest version of python, you can download from here.

Let's begin Django installation

  • Installing django on Virtual Environment
  • First setup virtual environment on your system as:

    C:\WINDOWS\system32>pip install virtualenvwrapper-win

    Make virtualenv where your project folder will exist:

    C:\Users\subham\projects>mkvirtualenv py1

    Here, virtual environment named as py1 you can give any name as you want.

    Install django on vitual environment

    (py1)C:\Users\subham\projects>pip install django
  • Set a project name inside 'projects' folder in this case
  • Set a project name

    C:\Users\subham\projects>django-admin startproject projectname

    Here, you can give any name instead of 'projectname'

    Working on py1 which is a virtual env we have made

    C:\Users\subham\projects\projectname>workon py1
    (py1)C:\Users\subham\projects\projectname>
  • Check django working
  • (py1)C:\Users\subham\projects\projectname>python manage.py runserver

Login to administrator

  • Go to localhost http://127.0.0.1:8000/admin
  • login from below ||

  • Create admin login username and password
  • (py1)C:\Users\subham\projects\projectname>python manage.py createsuperuser