我正在尝试创建一个Flask服务,在其中我想要将来自一个request.form的数据以JSON格式发送到另一个URL,请问有谁可以帮助我实现这个目标吗?
redirect(url_for('any_method'), json = json.dumps(my_form_dict))
当我尝试执行上述代码时,我遇到了以下错误:
TypeError: redirect() got an unexpected keyword argument 'json' The above is the error here.
json=request.form
即可... - josepdecid