For the life of me, I can't get my Favicon to work in Google Chrome. It works in IE and Firefox. It sometimes(?) works in Google Chrome when I am on the localhost. Once I deploy it, I can never get it to show up.
I have this in my HTML:
<link rel="shortcut icon" href="{{ url_for('static', filename='favicon.ico') }}">
I put this in my main Py file based on some other posts I have read:
@app.route('/favicon.ico')
def favicon():
return send_from_directory(os.path.join(app.root_path, 'static'),
'favicon.ico', mimetype='image/vnd.microsoft.icon')
If I go to /static/favicon.ico, it shows up. If I go to just favicon.ico, it shows up. I have cleared my cache and cookies a thousand times. I've tried everything. It will not show up.
I am not getting any error messages, but in the browser console, if I go to Favicon page directly, it does say this:
Resource interpreted as Document but transferred with MIME type image/x-icon: "http://localhost:5555/static/favicon.ico".
Maybe that is a hint of what is wrong?
What is going on?