What kind of screens request.form.to_dict()?

Hello! There is a piece of code where the data taken from the forms and entered into a database.
At this stage there is some adaptation of the html tags. I would like to know in what form to store such strings in the database.

cv_firstname = request.form.get('firstname')
 cv_lastname = request.form.get('lastname')
 cv_email = request.form.get('email')
 cv_phone = request.form.get('phone')
 cv_message = request.form.get('message')
 if cv_firstname and cv_lastname and cv_email and cv_phone and cv_message:
 cv = request.form.to_dict()
 cv['user'] = session['username']
 cv['status'] = 'Wait'
 cv['time'] = datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S")
 if db_count_user_cv(cv['user']) > 9:
 session['last_error'] = "Maximum of request reached :("
 session['last_url'] = "/home"
 return redirect(url_for('error'))
March 19th 20 at 09:25
0 answer

Find more questions by tags FlaskXSSPython