Django is a web framework. Thus, it needs a mechanism to generate HTML pages. HTML pages which django can generate have two parts:
- Static part: parts in HTML pages which are fixed.
- Dynamic part: parts in HTML pages which will be filled by data (Usually data which is pulled from database).
The mechanism which does this is called Template. A template has a special syntax which determines how dyanmic data must be inserted to HTML.
Rendering
In Django, we need to create an HTML string using a context data. Rendering is an action which fills the template with context data and returning the results as string.