0

我似乎在这里找不到问题...我无法显示网页上的图像。当我检查网页时,图像文件的位置似乎是正确的。无论如何,这是我的代码:HTML:

<body>
{% for key, value in team.items() -%}
    <h1>{{ value }}</h1>
    <img src="{{value}}.png" alt="{{ value }}">
{% endfor %}
</body>

Python:

app = Flask(__name__)


@app.route("/")
def main_page():
    return render_template("index.html",team=okc)


if __name__ == "__main__":
    app.run(debug=True)

任何帮助表示赞赏!:)

4

0 回答 0