思路: 获取查询关键字 查询数据库,获得查询结果 将查询结果返回模板文件 forms.py from flask_wtf import FlaskForm from wtforms import StringField,SubmitField from wtforms.validators import DataRequired class SearchForm(FlaskForm): keyword=StringField('keyword',validators=[DataRequired…