Python modules are also another python files .py files that consist of Python code. Most of the modules are available at the Python Standard Library and they are installed during the python standard installation. Other packages can be installed via pip. We can also create custom modules which are as per our requirements. Even they are comprised of additional python .py files.
The first route that is defined under urlpatterns is for django administrtion. You will be asked for your login credentials if you go to this url: http://127.0.0.1:8000/admin/
Second route which has a regex r’^$’ is defined for home. This denotes for an empty string. Therefore if the route is http://127.0.0.1:8000 it calls the home method and renders the view defined in that method.
A Django application is created within a Django Project. We have covered the creation of Django application on our previous blog. Go check it out for a detailed explanation. In order to create a new application we can do it by manage.py startapp command like shown below:
Welcome to the Blog series “Python Django Tutorial for Beginners“. Till this blog we have
In the earlier post we installed our first django framework project and installed bunch of
Once the virtual environment is setup and enabled you can begin installing Django Framework which is yet another python module for developing Web application. On your command type the following command just to make sure that the Virtual environment that you activated is working: