Reputation: 4344
I'd like to modify the existing Django comments framework to include star ratings. The Django site has good documentation on modifying the comments framework here, but I still have a few questions.
Upvotes: 0
Views: 1336
Reputation: 766
You can set HTML attributes into your inputs (class="star") as described here : https://docs.djangoproject.com/en/dev/ref/forms/widgets/#django.forms.Widget.attrs
Probably a IntegerField, keep it simple.
No, a user could hack the javascript and submit any value. Never trust user input ! Write your own validator :)
Upvotes: 2