Building Responsive Theme for Django Admin with Sidebar Menu

Responsive Django Admin

If you're looking for a version compatible with Django 1.8 just install


  • Responsive
  • Sidebar Menu
  • Easy install / setup
  • Support Django 1.11, 2.1, 2.2 and 3.0
  • Bootstrap 3
  • Python 3


Responsive Theme for Django Admin With Sidebar Menu

More screenshots


from pypi (recommended)

$ pip install bootstrap-admin

And don't forget to add bootstrap_admin in INSTALLED_APPS before the django.contrib.admin.


    # ...
    'bootstrap_admin', # always before django.contrib.admin
    # ...


Sidebar Menu

It is enabled by default. But if you remove django.template.context_processors.request from your context_processors.

Just disable it:


Branding - Overriding logo

If you want to use your own logo, you can achieve this by overriding the login.html and base_site.html, just like in Django Admin.

First, make sure the TEMPLATES setting in your is properly configured:

        'BACKEND': 'django.template.backends.django.DjangoTemplates',
        'DIRS': [os.path.join(BASE_DIR, 'my_django_project/templates')],
        'APP_DIRS': True,
        # other stuff

DIRS: You must set the location of your templates, an absolute path.

I'm assuming BASE_DIR is:

BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))

This pattern of creating a global templates folder could be useful for you to use for your base.html and other global templates.

More info:

Let me show you a project structure as an example:

├── my_django_project
│   ├── core
│   │   ├──
│   │   ├──
│   │   ├──
│   │   ├──
│   │   └──
│   ├──
│   ├── templates
│   │   └── admin
│   │       ├── base_site.html
│   │       └── login.html
│   ├──
│   └──

You can see I created a global templates/ folder, with another directory inside admin/ containing login.html and base_site.html.

Their respective contents are:


{% extends 'admin/base_site.html' %}
{% load static %}

{% block branding %}
    <a href="{% url 'admin:index' %}" class="django-admin-logo">
        <!-- Django Administration -->
        <img height="60" src="{% static "bootstrap_admin/img/logo-140x60.png" %}" alt="{{ site_header|default:_('Django administration') }}">
{% endblock branding %}


{% extends 'admin/login.html' %}
{% load i18n static %}

{% block branding %}
    <a href="{% url 'admin:index' %}" class="django-admin-logo">
        <!-- Django Administration -->
        <img height="60" src="{% static "bootstrap_admin/img/logo-140x60.png" %}" alt="{{ site_header|default:_('Django administration') }}">
{% endblock branding %}

More info:

Download Details:
Author: douglasmiranda
Source Code:
License: MIT License

#django #bootstrap #python 

What is GEEK

Buddha Community

Building Responsive Theme for Django Admin with Sidebar Menu
Ahebwe  Oscar

Ahebwe Oscar


Django admin full Customization step by step

Welcome to my blog , hey everyone in this article you learn how to customize the Django app and view in the article you will know how to register  and unregister  models from the admin view how to add filtering how to add a custom input field, and a button that triggers an action on all objects and even how to change the look of your app and page using the Django suit package let’s get started.


Custom Titles of Django Admin

Exclude in Django Admin

Fields in Django Admin

#django #create super user django #customize django admin dashboard #django admin #django admin custom field display #django admin customization #django admin full customization #django admin interface #django admin register all models #django customization

Ahebwe  Oscar

Ahebwe Oscar


How model queries work in Django

How model queries work in Django

Welcome to my blog, hey everyone in this article we are going to be working with queries in Django so for any web app that you build your going to want to write a query so you can retrieve information from your database so in this article I’ll be showing you all the different ways that you can write queries and it should cover about 90% of the cases that you’ll have when you’re writing your code the other 10% depend on your specific use case you may have to get more complicated but for the most part what I cover in this article should be able to help you so let’s start with the model that I have I’ve already created it.

**Read More : **How to make Chatbot in Python.

Read More : Django Admin Full Customization step by step

let’s just get into this diagram that I made so in here:

django queries aboutDescribe each parameter in Django querset

we’re making a simple query for the myModel table so we want to pull out all the information in the database so we have this variable which is gonna hold a return value and we have our myModel models so this is simply the myModel model name so whatever you named your model just make sure you specify that and we’re gonna access the objects attribute once we get that object’s attribute we can simply use the all method and this will return all the information in the database so we’re gonna start with all and then we will go into getting single items filtering that data and go to our command prompt.

Here and we’ll actually start making our queries from here to do this let’s just go ahead and run** Python shell** and I am in my project file so make sure you’re in there when you start and what this does is it gives us an interactive shell to actually start working with our data so this is a lot like the Python shell but because we did it allows us to do things a Django way and actually query our database now open up the command prompt and let’s go ahead and start making our first queries.

#django #django model queries #django orm #django queries #django query #model django query #model query #query with django

Einar  Hintz

Einar Hintz


Android Menu - Steps to implement Menu in Android - DataFlair

Types of Android Menu

Let us see the various types of menu in Android:

1. Android Options Menu

The Options Menu is a collection of options for an activity. It has a set of items that are useful to perform actions. It helps us to combine multiple actions together.

Following is an example of Options Menu:

Options Menu in Android

2. PopUp Menu

Pop-Up menu is a menu that displays a list of items in a popup window. A pop-up menu appears below the view by default, in case there is no space, it appears above it.

Android Pop Up menu

3. Contextual Menu

A contextual menu is a floating menu. It appears only when the users long-press an element or right clicks on that. It generally affects the selected element.

Contextual menu

#android tutorials #android menu #android menu types #contextual menu #menu android #menu in android #options menu #types of menu in android

anita maity

anita maity


Sidebar Menu Using Only HTML and CSS | Side Navigation Bar

how to create a Sidebar Menu using HTML and CSS only. Previously I have shared a Responsive Navigation Menu Bar using HTML & CSS only, now it’s time to create a Side Navigation Menu Bar that slides from the left or right side.


#sidebar menu using html css #side navigation menu html css #css side navigation menu bar #,pure css sidebar menu #side menu bar html css #side menu bar using html css

Orlo  Gottlieb

Orlo Gottlieb


Build a User Authentication Web App With Python and Django

User authentication is an integral part of most applications and in general can be seen as the process that which allows device to verify the identify of someone who connects to a network resource. In our case, these refers to our web app. Nowadays they are many technologies and web frameworks that make this task easy but in our case, we shall concentrate on the Django web framework to perform this task.
Django by default comes with a user authentication system. It handles user accounts, groups, permissions and cookie-based user sessions. For this tutorial we will be using mainly class base views(CBV) because they are a lot more easy to understand, save time and already have test built into them as compared to the functional base views(FBV) which are a lot more easy to customize but do not have test built into them.
In order to better understand and appreciate this tutorial, a basic understanding of python and the django framework is essential.

  • Django 3.0
  • python 3.8
  • Bootstrap 4 (for our frontend)
  • django-bootstrap4 2.3.1(for our forms)

#django #python-programming #django-girls #django-admin #django-rest-framework