In Django making web pages consists of three stages: defining URLs, writing views, and writing templates. First, you must define patterns for URLs. A URL pattern describes the way the URL is laid out and tells Django what to look for when matching a browser request with a site URL so it knows which...
Thursday, October 31, 2019
PollOpinion site in Django-3 ( The Django Admin Site)
When we define models for an app, Django makes it easy for us to work with our models through the admin site. A site’s administrators use the admin site, not a site’s general users. Now we’ll set up the admin site and use it to add some questions through the Question model.
Creating a superuser
Django...
Tuesday, October 29, 2019
PollOpinion site in Django-2 ( Creating the polls app)
A Django project is organized as a group of individual apps that work together to make the project work as a whole. For now, we’ll create a polls app and later we'll create other apps as and when required. Please make sure you still have running runserver in the terminal window as we did in the previous...