Day 7 : Learning Django Fundamentals

Django is a python web programming framework, which allows us to dynamically generate HTML and CSS for the backend of our website. Django combines the static web pages created using HTML and CSS with the endless possibilites of the programming language…

Django is a python web programming framework, which allows us to dynamically generate HTML and CSS for the backend of our website. Django combines the static web pages created using HTML and CSS with the endless possibilites of the programming language python, leading us to built dynamic web applications.

Django will allow us to write python code which will dynamically generate HTML and CSS.



HTTP

It stands for Hyper-Text-Transfer-Protocol, which is the protocol for how messages are going to be sent back and forth over the internet.

Example of a HTTP request method:-
Request method

Get tells us that we want to get that particular page. / simply indicates that we are requesting for the home page. HTTP/1.1 is the version of HTTP which we are using. Host tells us what URL we are trying to access the web-page for.

Example of an HTTP response:-
HTTP response



HTTP Status Codes:-

Status codes http



Starting an Django Project

To start a django project in the current directory, run this command:-

django-admin startproject project_name

The short intro to some starter files made by Django is given below:-

  • manage.py :- We will use this file to be able to execute commands on this django project.

  • settings.py :- If we want to change some settings to add features to our application or make modifications to how our application behaves.

  • urls.py :- This is the table of contents of all the urls on our web applications which ulitmately a user can visit.


Print Share Comment Cite Upload Translate
APA
Gaurav-Shekhawat | Sciencx (2024-03-29T01:15:24+00:00) » Day 7 : Learning Django Fundamentals. Retrieved from https://www.scien.cx/2021/08/19/day-7-learning-django-fundamentals/.
MLA
" » Day 7 : Learning Django Fundamentals." Gaurav-Shekhawat | Sciencx - Thursday August 19, 2021, https://www.scien.cx/2021/08/19/day-7-learning-django-fundamentals/
HARVARD
Gaurav-Shekhawat | Sciencx Thursday August 19, 2021 » Day 7 : Learning Django Fundamentals., viewed 2024-03-29T01:15:24+00:00,<https://www.scien.cx/2021/08/19/day-7-learning-django-fundamentals/>
VANCOUVER
Gaurav-Shekhawat | Sciencx - » Day 7 : Learning Django Fundamentals. [Internet]. [Accessed 2024-03-29T01:15:24+00:00]. Available from: https://www.scien.cx/2021/08/19/day-7-learning-django-fundamentals/
CHICAGO
" » Day 7 : Learning Django Fundamentals." Gaurav-Shekhawat | Sciencx - Accessed 2024-03-29T01:15:24+00:00. https://www.scien.cx/2021/08/19/day-7-learning-django-fundamentals/
IEEE
" » Day 7 : Learning Django Fundamentals." Gaurav-Shekhawat | Sciencx [Online]. Available: https://www.scien.cx/2021/08/19/day-7-learning-django-fundamentals/. [Accessed: 2024-03-29T01:15:24+00:00]
rf:citation
» Day 7 : Learning Django Fundamentals | Gaurav-Shekhawat | Sciencx | https://www.scien.cx/2021/08/19/day-7-learning-django-fundamentals/ | 2024-03-29T01:15:24+00:00
https://github.com/addpipe/simple-recorderjs-demo