What is Django and Python Web framework- Step 1

What is Django?

Django is Python web framework that is used for rapid web development which follows the 
mode-view-template (MVT) architectural pattern.Django CMS is a free and open source content management system platform for publishing content on the WWW and intranets.

Django is a collection of Python libs allowing you to quickly and efficiently create a quality Web application and is suitable for both frontend and backend.
  • Named after famous Guitarist Django Reinhardt
  • Developed by Adrain Holovaty & Jacob Kaplan-moss
  • Created in 2003 and open sourced in 2005
Who uses Django?
  1. Instagram: - We all know Instagram is the place to share your life in pictures. The Instagram website is a Python website that allows users to browse, find and post pictures. 
  2. Pinterest: - Pinterest is a visual discovery tool that allows users to showcase their interests through the posting of pictures. Users can also follow and share other users’ pictures and content all through the power of Django.
  3. Quora: - Quora is the number one place online to ask a question and receive answers from a community of individuals. On their Python website, relevant results are answered, edited, and organized by these community members.
  4. Bitbucket, NASA, Mozilla, National Geographic, Discovery channel 
Some of the popular websites that are created using Django and Python there are much more.

Django Architecture
Django Architecture

  1. The URL dispatcher(urls.py) maps the requested URL to a view function and call it.If caching is enabled the view function can check to see if a cached version of the exists and bypass all further steps, returning the cached version instead.
  2. The view function(views.py) performs the requested action, which typically involves in CRUD operations with the database.
  3. The model(models.py) defines the data in python and interacts with it.
  4. Template returns the HTML.
  5. As a database option,
    1. If you’re using PostgreSQL, you’ll need the psycopg2 package.
    2. If you’re using MySQL, you’ll need a DB API driver like mysqlclient. 
    3. If you’re using SQLite you might want to read the SQLite backend notes.
    4. If you’re using Oracle, you’ll need a copy of cx_Oracle.

Project Directory Structure 


Django CMS admin panel



Here, You can see I have created an app(MyMusicapp) in Django every section such as (Home, About, etc) is called an app and we will discuss this later.


Happy coding and keep sharing !!!!  


Comments

Post a Comment

Popular posts from this blog

Creating a project in Django - Step 3

Intall Django - Step 2