Python Django Blog In Less Than 20 Minutes - Blogging website tutorial
HTML-код
- Опубликовано: 30 янв 2025
- In this Python Django blog tutorial, I will show you how to set up a very basic blog using Django in less than 20 minutes.
I begin the video with a short introduction of the project, and then I continue by creating a virtual environment we can build the blog in.
Django is a framework based on Python for building web sites and web application. By going through this tutorial, you will learn hos easy and quick you can set up a simple blog using Django.
It's not very fancy, but the point of this video is to learn Django.
I have also written this video as a blog post:
codewithstein....
Source code:
github.com/Ste...
Bulma:
bulma.io/
My patreon:
/ codewithstein
#codewithstein #djangoblog #learndjango #djangotutorial
You made this look so easy! And I like how you explain things! I’ll have to watch this again when I’m not at work. I used a blog tutorial from a book at from the start it was very hard to understand but slowly I was getting it! With this video it clears up even more and you went through everything in a short amount of time! Thank you!
That sounds awesome 😁 Glad I could help 😁
Thank you, man! I was looking for tutorial like this. I can't express how much grateful am I for this video to you. Subbed and liked!
THANK YOU SOOO MUCH 🙏❤️!
Thank you for the feedback :-D It means a lot :-D
This video was great! Simple, clear, short, and it all worked! Thanks!
Thanks, glad you liked it 😁
Nothing can get better than this. Thank you so much. I needed this for a shool project.
Nice :-D
I made a hosted Django blog in ruclips.net/video/znZctl1NCX8/видео.html
Thank you very much Boss for publishing such a beautiful blog video I have subscribed your channel for many more such videos ❤
Thank you si much for the feedback :-D
Thank you for a quick and simple Django tutorial!
You’re welcome 😄😄
Wow, you made that look easy, trying it now.. thank you!
Thanks :-D Enjoy!
Thank you for this very nice tutorial.
Your welcome 👍🏻😁
thank you very much, this really helped
You’re welcome 😁
Time is killing us but you are the person killing the time
Hehe :-)
I am loving django
Me too 👍🏻
@@CodeWithStein It's a modern and complete framework not like EXPRESS which you have to implement almost everything
I totally agree, it is the best 😁
Thank you very much for this video.
It really helped me
You’re welcome 😁 I’m glad to hear that 😁
Is it production ready I mean dosn't require security front/backend dev. Thank is very good and simple.
Hey, this could absolutely be put into production. Thanks :-D
best tutorial ever .. thank u
Thanks :-D
That’s was great! Thank you!))
Thanks :-D
Amazing Video!
Thank you 😁😁
Thanks for the easy lessons!
If I want to create login page for new users and post blogs using that account, what todo?
You're welcome :-D
It's a bit more than I can explain here in a comment, but you can check out my video series on how to build a SaaS. I create user sign up and similar there ;-)
you are doing well sir
Thank you :-)
@@CodeWithStein anything on e commerce sir... we missed you so much
It will come, but not for a little while now. I want to finish the Job Board series.. When that's done, I'm going to make some episodes where I add vendors ;-)
@@CodeWithStein ok sir. that means we should hold on for like one month sir
Hopefully not a full month! I want to finish the job board series asap and then the vendors, but probably a couple of weeks ;-)
Hey Stein, thanks for this it is excellent!! How do I add categories to this?
Heyhey Amritpal :-) Thank you :-)
It's a bit too much to explain here, but you can check out my other blog tutorial:
ruclips.net/video/3X6qzWxlQOI/видео.html
This is similar, but here I add categories as well ;-)
Great. simple, fast explanation.
Thanks 😁😁
may I ask what is the quickest way to access the created website?
What do you mean?
This man amazing
Thanks 😁😁
Great tutorial
Thanks :-D
Hi Stein, may I ask you where you learn all this? Also Vue.JS etc?
Hi! Of course you can Joris!
I have learned these languages and frameworks from all over the place :P Much of the knowledge I have comes from reading the docs and trying to build projects for my self. I like to create videos where I teach the things I learn because it makes me learn even more :-)
great tutorial, everything is well explained, but no matter what i do, i keep getting the "Reverse for 'post_detail' not found. 'post_detail' is not a valid view function or pattern name." error. I ended up copying the whole project page by page, but the error is still there.
edit: sorry, false alert. i wrote a hyphen instead of underscore in urls :D.
thx again for all these amazing tutorials !
Thanks for the feedback ☺️ I’m glad you fixed it 😁
nice the only thing that i have to do is make a form for post so u can create post. but overall is Good tutrial
Hey, thanks :-D You can easily just use the Django admin area for this? :-)
@@CodeWithStein i know but i want to make for users.
god damn for some reason in my urls.py "path" was not imported. I spend half an hour until I figured that out.. my first django tutorial lol. phew, happy I didnt give up.
Weird :s but nice to hear that you solved it 😁
Well you can add slug automatically in the model just by overiding the save method like
from django.utils.text import slugify
from django.db import models
class Post(models.Model):
#your fields
def save(self, *args, **kwargs):
self.slug = slugify(self.title)
super().save(*args, **kwargs)
Yes, I know. It's a cool feature that should have been added to this little video :-)
@@CodeWithStein This video is too perfect!
I like it and subbed to you. :)
how do i build a blog that can upload video not using youtube. I can upload pictures in my blog but i want to upload video
Instead of using an "ImageField" in the models.py file, you just need to use a FileField. Here you should be able to upload a video, then you show it by using the HTML-video tag :-)
I can't get the Django page or admin page to display? Can you help? I'm on Windows
Hi, are you getting any errors?
Good 👍👍
Thank you :-D
i cant conect the url with views. it doesnt recogrnize blog
Hi, that sounds weird. Can you paste the error here?
Too good
Thank you :-D
How can I delete the blog , pls reply
Hey, what do you mean? Can’t you just delete the folder on your computer?
@@CodeWithStein sry, I mean how can i add CRUD option
thank you
You're welcome :-D
return render(request, 'blog/frontpage.html', {'posts':posts})
^
IndentationError: unindent does not match any outer indentation level
i am getting this error
Then there is a problem in your file where you mix spaces and tabs ;-)
I'm Following You
Great :-D That means a lot!
@@CodeWithSteinSir, I've a lot to learn from you.
@@sazidahmed3012 That sounds good :-) More videos and more to learn will come :-D
@@CodeWithStein Thank You Sir
I didnt understand how to create a user to sign to admin
You should use the "python manage.py createsuperuser" command, this creates an user for the admin area ;-)
data not showing on django template
Hmm, do you Get any errors? :s
bookmark 9:52
:-=
I got "no changes detected" when i went to update the cmd
Hi, did you remember to add the apps in INSTALLED_APPS list?
@@CodeWithStein i will re check the programme, i added 'blogs 'only
OMG it's amazing... U make it so easy.. subscribe this channel after watching this one video... Thank you
Thank you so much 😀😀😀 glad you liked it 👍🏻👍🏻
Upload flask tutorial pls
Maybe some day 😉
Sir
Yes? ☺️
I am not understanding
What don't you understand? :-)