fix: force favicon refresh via /favicon.ico
This commit is contained in:
4
app.py
4
app.py
@@ -252,11 +252,13 @@ def health():
|
||||
|
||||
@app.route("/favicon.ico")
|
||||
def favicon():
|
||||
return send_from_directory(
|
||||
response = send_from_directory(
|
||||
app.static_folder,
|
||||
"img/favicon.png",
|
||||
mimetype="image/png",
|
||||
)
|
||||
response.headers["Cache-Control"] = "no-store, max-age=0"
|
||||
return response
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
||||
@@ -4,8 +4,9 @@
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title>Вход в админку | InfraIT</title>
|
||||
<link rel="icon" type="image/png" href="{{ url_for('static', filename='img/favicon.png') }}">
|
||||
<link rel="shortcut icon" href="{{ url_for('static', filename='img/favicon.png') }}">
|
||||
<link rel="icon" type="image/png" href="{{ url_for('favicon') }}">
|
||||
<link rel="shortcut icon" href="{{ url_for('favicon') }}">
|
||||
<link rel="apple-touch-icon" href="{{ url_for('favicon') }}">
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Montserrat:wght@600;700;800&display=swap" rel="stylesheet">
|
||||
|
||||
@@ -4,8 +4,9 @@
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title>Настройки сайта | InfraIT</title>
|
||||
<link rel="icon" type="image/png" href="{{ url_for('static', filename='img/favicon.png') }}">
|
||||
<link rel="shortcut icon" href="{{ url_for('static', filename='img/favicon.png') }}">
|
||||
<link rel="icon" type="image/png" href="{{ url_for('favicon') }}">
|
||||
<link rel="shortcut icon" href="{{ url_for('favicon') }}">
|
||||
<link rel="apple-touch-icon" href="{{ url_for('favicon') }}">
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Montserrat:wght@600;700;800&display=swap" rel="stylesheet">
|
||||
|
||||
@@ -11,8 +11,9 @@
|
||||
<meta property="og:description" content="Компьютеры, серверы и сети для бизнеса без простоев. Татарстан и Казань с выездом, Россия удаленно.">
|
||||
<meta property="og:type" content="website">
|
||||
<meta property="og:locale" content="ru_RU">
|
||||
<link rel="icon" type="image/png" href="{{ url_for('static', filename='img/favicon.png') }}">
|
||||
<link rel="shortcut icon" href="{{ url_for('static', filename='img/favicon.png') }}">
|
||||
<link rel="icon" type="image/png" href="{{ url_for('favicon') }}">
|
||||
<link rel="shortcut icon" href="{{ url_for('favicon') }}">
|
||||
<link rel="apple-touch-icon" href="{{ url_for('favicon') }}">
|
||||
<meta name="yandex-verification" content="{{ settings.yandex_verification }}">
|
||||
{% if settings.yandex_metrika_id %}
|
||||
<script>
|
||||
|
||||
Reference in New Issue
Block a user