If statement in Django template

If tag in Django template

In this Django tutorial, I will explain the use of the if-else statement in a Django template. I will show some of the examples of the use cases of an if-else statement in a Django template. HTML pages are static in nature. However, Django templates can make a page dynamic using various techniques. For example, …

Read more

Django get all data from POST request

Django get all data from POST request

In this Python Django tutorial, I will explain how to get data from a POST request in Python Django in various ways. I will demonstrate this with the help of some examples. How to get POST request data in Django Django pass POST data to view Django post request example Django get post data list …

Read more

Convert HTML page to PDF using Django in Python + PDF Invoice

Convert HTML page to PDF using Django

You might have faced various scenarios when you needed to convert an HTML document into a PDF file in Python using Django. In Django, you can implement this feature by using some libraries that we will discuss in this article. In this article, you will learn to convert HTML pages to PDF using Django. You …

Read more

Get URL parameters in Django

Django URL parameters string

In Django, you can also pass parameters as part of the URL. In this Django tutorial, you will learn how to get URL parameters in Django. In various web applications, you might have seen some URLs that end with some parameters. For example, look at the below URL: The above URL fetches the products page …

Read more

How to get data from get request in Django

Django get data from get request example

In this Django tutorial, you will learn how to get data from get request in Django. When you send a request to the server, you can also send some parameters. Generally, we use a GET request to get some data from the server. We can send parameters with the request to get some specific data. …

Read more

Python Django length filter

Check length of a string in Django

In this Python tutorial, I will explain how to check the length of a string or a list in a Django application in Python. Check length of a string in Django Length of string in Django template Django template length of list Django template if length greater than Get length of queryset Django Check length …

Read more

Django for loop

Django for loop break

In this Django tutorial, we will learn about the Django for loop. Here we will learn how to use a for loop in Django. And we will also discuss different examples related to having a for loop in Django. These are the following topics that we are going to discuss in this tutorial. Django for loop …

Read more

Python Django group by

Python Django group by using annotate

In this Django tutorial, we will learn about the “Python Django group by” and we will also discuss some examples related to it. These are the following topics that we are going to discuss in this tutorial. Python Django group by Python Django group by annotate Python Django group by filter Python Django group by …

Read more

Python Django get – Everything you need to know

Python Django get post data

In this Django tutorial, we are going to learn about “Python Django get“. We will also cover some topics like- Python Django get post data, Python Django get_or_create, etc. Here is the complete list of topics that we will discuss in this tutorial. Python Django get Python Django get request parameters Python Django get_or_create Python …

Read more

Python Django filter

Python Django filter and

In this Django Tutorial, we will discuss “Python Django filter” and we will also discuss different examples related to filters in Django. And we are going to cover the following topics in this tutorial. Python Django filter Python Django filter or Python Django filter and Python Django filter in Python Django filter not equal Python …

Read more