2017年12月20日

实现搜索功能

摘要: 1.准备视图函数search() 2.修改base.html 中搜索输入框所在的 3.完成视图函数search() a.获取搜索关键字 q = request.args.get('q’) b.条件查询 qu = Question.query.filter(Question.title.contain 阅读全文

posted @ 2017-12-20 20:10 083李笑晴 阅读(99) 评论(0) 推荐(0) 编辑

完成个人中心—导航标签

摘要: 1.个人中心—视图函数带标签页面参数tag@app.route('/usercenter/<user_id>/<tag>')def usercenter(user_id, tag): if tag == ‘1': return render_template('usercenter1.html', 阅读全文

posted @ 2017-12-20 20:00 083李笑晴 阅读(97) 评论(0) 推荐(0) 编辑

导航