Article default image
jQuery click() Method

Theclick()is an inbuilt method in jQuery that triggers the click event or attach a function to run when a click event occurs. Syntax: -Trigger the click event for the selected …

read more
Article default image
jQuery change() Method

The change method is a Jquery Event Method. It is an inbuilt methodoccurs when the value of an input field has been changed(only works on <input>, <textarea> and <select> elements).The …

read more
Passing multiple variables to Django Template's Assignment Tags image
Passing multiple variables to Django Template's Assignment Tags

Django template tags allows passing multiple variables or values to the assignment tags. Most people knows passing one variable, but not many and we see many questions how to pass …

read more
Create sitemap for Django application via sitemap framework's GenericSitemap class image
Create sitemap for Django application via sitemap framework's GenericSitemap class

Sitemaps are very critical for SEO. For a Django application, how can we add sitemap? The Django applications has dynamic content and it is almost impossible to recreate a sitemap …

read more
Difference between null=True, blank=True in django image
Difference between null=True, blank=True in django

The main differnce for null and blank is null=True/False related to database blank=True/False related to form validation, used when is called. Simply defines database should accept NULL values, on other …

read more
How to install  and do minimum configuration of Mezzanine image
How to install and do minimum configuration of Mezzanine

This article assumes that you are familiar with installing and configuring Django. Mezzanine is a Django project athttp://mezzanine.jupo.org/.It is licensed under BSD.It can be used, modified, and redistributed commercially. There …

read more
Create sitemap for static  pages in Django application image
Create sitemap for static pages in Django application

We have both static and dynamic pages in a Django application. How will we add static pages to sitemap? It is very simple. As first step, we have to include …

read more
Create sitemap using Django sitemap framework image
Create sitemap using Django sitemap framework

The sitemap framework is very flexible. We can use it to create sitemap for any item in the database, along with custom configurations. The very basic step is to addto …

read more
Python sort array of dictionaries by value in the dictionary image
Python sort array of dictionaries by value in the dictionary

One of the cases we face in programming is sorting an array of dictionaries by value in the dictionary. In Python, it is possible to write a one-liner to achieve …

read more
What is @permalink and get_absolute_url in Django? image
What is @permalink and get_absolute_url in Django?

What is and in Django? When and why to use it? Both and are concerned with allowing you to reverse the URL for a particular object and should be used …

read more
Python 3 - Django: ImportError: No module named 'django.core.urlresolvers' image
Python 3 - Django: ImportError: No module named 'django.core.urlresolvers'

Python 3 - Django 2.x: ImportError: No module named 'django.core.urlresolvers' is a common error we get when we migrate from python 2.x to python 3.x and use latest Django > …

read more
Django - check for null in database image
Django - check for null in database

In django, the NULL valuein the database field is tested with field lookup It takes eitheror, which correspond to SQL queries ofand, respectively. Example: SQL equivalent:

read more
Django Signals image
Django Signals

Django Signalsallowsdecoupled(independent) applicationsget notified when certain events occur elsewhere in the framework with the help of 'signal dispatcher'. The'signal dispatcher' is Django's mechanism usedto send and receive messages between different …

read more
Defining and sending django signals image
Defining and sending django signals

Defining signals class(providing_args=list) All signals areinstances. Theis a list of the names of arguments the signal will provide to listeners. This is purely documentational, however, as there is nothing that …

read more
Django Q objects image
Django Q objects

A() is an object used to encapsulate a collection of keyword arguments. objects can be combined using theandoperators. Which is equivalent to the SQLclause: objects can be negated using theoperator, …

read more
Is autoescape off in django safe? image
Is autoescape off in django safe?

The autoescape would be a protection against cross site scripting, not sql injection. Turning autoescape off would mean you trust what is in "text", wherever it came from, not to …

read more
Cross-Site Request Forgery (CSRF) in simple words image
Cross-Site Request Forgery (CSRF) in simple words

Cross-Site Request Forgery (CSRF) is an attack that forces an end user to execute unwanted actions on a web application in which they're currently authenticated. CSRF attacks specifically target state-changing …

read more
Django field lookup - contains and icontains image
Django field lookup - contains and icontains

Field lookups are how we specify the conditions in the WHERE clause of an SQL. They are specified as keyword arguments for QuerySet methodslike filter(), exclude() and get(). Check if …

read more
Django field lookup - exact and iexact image
Django field lookup - exact and iexact

Field lookups are how we specify the conditions in the clause of an SQL. They are specified as keyword arguments for QuerySet methodslike, and . As a convenience when no …

read more
Django-Compress compressJs/CSS of your application forbetter performance of the application image
Django-Compress compressJs/CSS of your application forbetter performance of the application

Django-compress is a Django application that allows us to compress our CSS and Javascript for better performance of the the application. The django compress provides a tag named compress that …

read more