Welcome to the first part of the web application development guide in Django.
Next helpful articles in this series will be published in about 1-3 days intervals. As long as there is something to write about or you'll have ideas about what to do next guides, the series of articles will be active :)
So far, we're starting!
Django is a framework designed to create and manage web applications, written in Python. It facilitates working with a database and templates, thanks to which it reduces the time of work and the required skills to support the page code.
With so many words of introduction, it's time to look at the code.
First install django (required: python v. 3.x)
pip3 install django
then create a new project, which you can name freely. This one will have the name 'mysite'.
django-admin startproject mysite
Go to the mysite
folder and start the application for the first time.
python3.6 manage.py runserver
After a moment, you will get an error in the console about a few unrealized migrations, do not worry about it, we'll take care of it in a moment.
Start your browser and enter 127.0.0.1:8000
. You will see such a view in front of your eyes:
Congratulations, you've successfully passed the first configuration.
Now, let's fix the migration error. Abort the previous command (by
ctrl + c
or cmd + c
) or open a new console and then type
python3.6 manage.py migrate
.
Now everything works as it should :)
In the next article, I will describe the creation of the first view, Cya.
@valium purchased a 28.77% vote from @promobot on this post.
*If you disagree with the reward or content of this post you can purchase a reversal of this vote by using our curation interface http://promovotes.com
Congratulations @valium! You have completed the following achievement on the Steem blockchain and have been rewarded with new badge(s) :
Click here to view your Board
If you no longer want to receive notifications, reply to this comment with the word
STOP
To support your work, I also upvoted your post!