I want to know if it is possible to directly modify and save a model instance in the HTML Template and not via a view and extra URL.
My user has a Boolean Property, I want to display it as a toggle button on the website and the user should be able to toggle it on or off without leaving the website or reloading it. class User(AbstractBaseUser, PermissionsMixin): ... autoplay_enabled = models.BooleanField(default=True) ... Is this possible without an extra view or form? Basically I just need to set request.user.autoplay_enabled = False (or True) and then *save()* it If I can't modify the object directly in the HTML template is it at least possible to just execute a function I have defined somewhere in my Python code, without having the need to create a new view? -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/django-users. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/abed6766-0bb5-40d9-a2b3-065e17633937%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.

