Jezzy Grey

Generation

css from descriptionSun, 19 Feb 2023

The views class for the django framework. Gets data from the form that is displayed in the html template

class IndexView(FormView): template_name = 'index.html' form_class = ArticleForm success_url = '/search/' def form_valid(self, form): self.request.session['name'] = form.cleaned_data['name'] self.request.session['author'] = form.cleaned_data['author'] return super().form_valid(form)

Questions about programming?Chat with your personal AI assistant