Primarne pro 3.IM - Django aplikace pro jednoduché vytvoření formuláře
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

12 lines
374 B

from django.shortcuts import render
from .forms import feedbackForm
def indexView(request):
form = feedbackForm
if request.method == "POST":
#print(request.POST) #potrebuju zkontrolovani
form = feedbackForm(request.POST)
if form.is_valid():
form.save()
context = {'form':form}
return render(request,"index.html", context)