Комментарии:
I've tried MPTT but it's extremely cumbersome :(
ОтветитьDear professor, firstly I congratulate you for the clarity and effectiveness of your videos... my favorites! Secondly, I would like to ask you or request your help to program an app that allows me to budget with chapters, subchapters, subsubchapters and cost items. Thanks since now.
ОтветитьLove your videos
ОтветитьGood content
Ответить1. Settings: taggit
pip install django-taggit
2.Models:
from taggit.managers import TaggableManager
class Post():
tags = TaggableManager()
makemigrations
migrate
3.Url:
import post_list
path('tag/<slug:tag_slug>/',tag, name='tag'),
4.Views
from django.shortcuts import render , redirect , get_object_or_404
from taggit.models import Tag
def tag(request, tag_slug=None):
# post tag
tag = None
if tag_slug:
tag = get_object_or_404(Tag, slug=tag_slug)
posts = Post.objects.filter(tags__in=[tag])
context = {
"posts" :posts,
"tag" : tag
}
return render(request,'post_list.html',context)
5. Post.html
<p>
<strong>Tags:</strong>
{% for tag in post.tags.all %}
<a href="{% url 'tag' tag.slug %}" style="background-color : white;">
{{tag.name}}
</a>
<!-- {% if not forloop.last %}, {% endif %} -->
{% endfor %}
</p>
мой ник (забивной мансур228)
Ответитьзаходи в бравл старс лысый размажу
Ответитьwe need your github source codes
ОтветитьHi John, I rarely comment on any videos but man this was brilliant. I have really struggled with Django but you have really demystified the whole thing. Thank you.
ОтветитьHow can we ordered comments based on the date ?
ОтветитьHello, love you videos...I am implementing the comments but the form does not fetch the data. I can see the form, put does not send data.
Ответитьthat course is perfect
easiest 50$ I ever spent
Seriously amazing small small points explaining in simple manner keep sharing!!!!!
ОтветитьThank you so much for this series! can you please make a video of how to add last updated field?
ОтветитьVery Nice Tutorial. Only Difficulty do you provide this code some where , because when some one access this playlist from the middle he needs to compare the differences like imports variables, but logic wise its provide all. if possible please provide code somewhere
ОтветитьInitially, I thought I was playing the video at 2x speed. LOL!
Ответитьnice video
ОтветитьAwesome tutorial!! Please make a tutorial about download a file from Django.
ОтветитьHow to use comment form in details view instead of use different view????
Ответитьvery good ❤
please teach us how to create follower and following system
SO helpful!
Ответитьrealtime coments ??
Ответитьgood jobs broo
Ответитьyour video forces me to subscribe :)
Ответитьwould you add a comment reply function? Thanks!
ОтветитьWill you continue with comments?
ОтветитьHi! I'm having trouble getting the information to show up on screen. The admin center shows everything is fine but its just not coming up on the screen I redid this many times. Is this with the detailview or something else? if it isn't could you tell me how to get it to work very simply with detailview? Thanks!
ОтветитьExplained well!
Ответитьi like comments
Ответитьhow about including author of comment in comment model
Ответитьcan this be applicable for all the blogs on our website??
ОтветитьHi, can you please help, I'm building a website, and used the same code to add comments, the comments are being going to database but not reflecting on the site.
ОтветитьThank you so much.
Ответитьthis guy is just awsome he has every video i need
ОтветитьCan You please also do a video on generic Content_Type with comments
ОтветитьGreat tutorial, as always!
And please, make more videos about comments (replying, liking them etc.), they would be extremely helpful.
Thanks man. I'm building a social media and this is the most important feature we were missing :)
ОтветитьI was struggling with this matter for a few hours and almost going mad (beginner struggles, heh) and you just saved me now. Thanks man! Subbed you!
ОтветитьI did it with foreign key and also add reply system..
Ответить