【发布时间】:2020-01-15 04:12:18
【问题描述】:
我有通过 python 的烧瓶应用程序。在我的页面中,有三张图片,但烧瓶只显示其中一张。
我不知道问题出在哪里。
这是我的代码。
HTML
<div class="col-xs-4">
<img style="width:40%;padding:5px" src="static/tomato.png"/>
<br>
<button class="btn btn-warning"><a style="color:white;" href="http://127.0.0.1:5000/detect">Tomato Analysis</a></button>
</div>
<div class="col-xs-4">
<img style="width:40%;padding:5px" src="static/grapes.png"/>
<br>
<button class="btn btn-warning"><a style="color:white;" href="http://127.0.0.1:5000/detect">Grape Analysis</a></button>
</div>
Python
@app.route("/main")
def index():
return render_template('gui2.html')
它显示了tomato.png,但它没有显示grapes.png,这是什么问题,我该如何解决。
我也在使用 electron.js。运行 python 脚本后,我正在运行 nmp start。
错误输出为:
GET /%7B%7B%20url_for('static',%20filename%20=%20'image/corn2.png')%20%7D%7D HTTP/1.1" 404 -
感谢任何帮助...
谢谢
【问题讨论】: