
Learn how Django, built on Python, powers data-driven web apps by building a landing page to collect emails and user data, and applying admin-only permissions for secure access.
Explore building a Django landing page with user signup, admin data management, and note entries. See how Django models, forms, templates, URL routing, and Bootstrap create a responsive web app.
Explore where to get help for your Django project by visiting the course GitHub repository, joining discussions for questions and bugs, and reviewing code and examples.
Learn the Django requirements for your first web application, including Python version needs (Python 3.8+ for Django 4.1), version options, and backwards compatibility to guide project setup.
Verify Python version, create and open a project folder in VS Code, and create and activate a virtual environment with python -m venv for the Django project.
activate your virtual environment, install django via a requirements file, create a django project in src, then run the server to launch your first django app with sqlite
Create a Django view in views.py that returns an HttpResponse saying Hello world, then map it to a URL to render a custom home page and explore the Django admin.
Map URLs to a Django view and assign the home page to an empty path to render a hello world response, then note trailing slash behavior and redirects.
Create a templates folder beside manage.py and render index.html with Django's render, using a templates path and the request argument; configure Pathlib-based templates in settings.
Learn to use Django template inheritance by creating base.html and home.html, extending base, and replacing blocks with content using extends, block, and block.super, then render via views and URLs.
Explore how Django renders templates with context variables, using f strings and dictionaries to substitute values in Home.html, create reusable A, B, C pages, and apply Bootstrap for responsive styling.
Learn to integrate Bootstrap 5.2 into a Django project by using template inheritance and the include tag to modularize base, nav bar, CSS, and JavaScript, improving page styling and responsiveness.
Create and render your first Django form to collect user data on the landing page, starting with an email field, and learn to handle post requests and CSRF protection.
Learn how to validate data with Django forms by processing request.post or none and using form.is_valid and cleaned_data. Implement field and non-field errors, custom email validation, and confirm email matching.
Style Django forms by applying bootstrap form-control classes to all fields using an init method, iterating over self.fields, updating widgets and attributes, and optionally exploring Django crispy forms for layouts.
Refactor a Django project by turning views and forms into a dedicated app component called landing_pages using snake_case, configure imports and urls, and prepare to add models by updating settings.
Create your first Django model and map form data to a SQLite database, validate the email with form clean methods, and store as a landing page entry.
Create and apply django migrations to translate models into sql tables, manage database changes with make migrations and migrate, and understand automatic id fields and sqlite usage.
Learn to manage data with the Django admin by creating a super user, migrating the database, and registering a landing page entry model with display and search features.
Save form data to a landing page entry model in a Django view by creating an object or using objects.create, then save to persist the data.
Create a Django ModelForm that merges the landing page entry model with form fields, using a meta class to specify name and email and enabling save via form.save.
Modify a Django model by making fields optional with blank=true and adding a date time field for timestamps, then run make migrations and migrate.
Learn how to write an automated Django test with manage.py test, validate inactive items using query sets and filters, and explore fixtures and migrations to safeguard your landing page data.
Leverage Django fixtures to dump data and load data into a test database via manage.py, enabling fixtures-based testing with app-specific data.
Define a Django view to list database items by querying all objects, pass them as object_list to list.html, and render via a dedicated URL pattern for end users.
Attach a notes field to the landing page entry model, migrate, and filter entries by the logged-in user to secure content; leverage request.user in views and templates.
Learn to implement a dynamic landing page entry detail view in Django by routing a path with id to a detail view and rendering the item in a detail template.
Refactor Django forms with a bootstrap form mixin to reduce repetition, create a model form for notes, bind it to an entry instance, and use get_absolute_url with HttpResponseRedirect for saves.
Learn how to use Django's messages framework to show short-lived notifications after form submissions, render them in templates with bootstrap alerts, and tune with tags and dismissible alerts.
Master bootstrap layouts with container and container-fluid, rows and columns, and breakpoints to control wrapping and alignment. Use margins, padding, and auto margins to center content on the landing page.
Polish the landing page by integrating a Bootstrap hero, a responsive video, and a sign-up form into a fluid grid using rows, columns, and ratios.
Celebrate completing the series and your first django project. Plan your next steps by identifying questions about get_absolute_url and auto path creation, explore the django documentation, and build another project.
Building a web application has never been easier thanks to open source. In this course, we're going to go step-by-step building a Django web application. If you've never used Django before, this is the course for you.
Django is one of the most popular web frameworks written in the Python programming language. Django and Python are both open source and free to use commercially. This means you don't have to pay a dime to create amazing software and impact people all around the world. Django powers many websites in the world including: Instagram, Pinterest, NASA, Baserow, this website, and so many others.
The goal of this course to teach you the fundamentals of Django while also creating a very practical project. Building something real is important because it gives you the context of how, when, and where to use a lot of Django's great features.
Django sits right in the middle of creating an app from scratch and using something like Wordpress. This means we have a lot of features we could implement along with a lot of features that just work by default. This makes Django incredibly flexible so that we can go far beyond what a blogging platform offers while being faster than starting from absolute 0.
For our User Interface, we're going to learn the fundamentals of Bootstrap. Bootstrap makes our Django project look far more professional in very little time. Not only that, we'll also have a much better user experience by leveraging many of Bootstrap's built-in features.
If we were building a house, Django would be the plumbing, the walls, and electricity while Bootstrap is the interior decorator.
Here's a few things we'll cover:
Django version 4.1 (or even 2.2+)
Python version 3.10 (or 3.8+)
Bootstrap 5.2+
Collecting data from users
Rendering HTML templates and documents
Password-protected pages & user-type permissions
Modeling data in Django as it relates to a spreadsheet
Dynamically display content based on stored database data
Much more