• Support
  • Inconsistent display across browsers

The issue

Someone on our forum inserted an image in his post. The image displays in Firefox ans Safari, but not in Chrome. The image renders as an image even in the editor so I assume it is not following the syntax asking for the image to be from a URL. Perhaps it was pasted in the text editor. It is the first post in this discussion: https://lepointdarret.com/public/d/44-logo-pour-le-forum

I would like to get the image to display on Chrome also.

Flarum information

Flarum core 1.6.3
PHP version: 7.4.33
MySQL version: 10.3.37-MariaDB-log-cll-lve
Loaded extensions: Core, date, libxml, openssl, pcre, sqlite3, zlib, bz2, calendar, ctype, curl, hash, filter, ftp, gettext, gmp, SPL, iconv, pcntl, readline, Reflection, session, standard, shmop, SimpleXML, mbstring, tokenizer, xml, i360, bcmath, dba, dom, enchant, fileinfo, gd, imagick, imap, intl, json, ldap, exif, mysqlnd, mysqli, odbc, PDO, pdo_mysql, PDO_ODBC, pdo_pgsql, pdo_sqlite, pgsql, Phar, posix, pspell, snmp, soap, sockets, sysvmsg, sysvsem, sysvshm, tidy, timezonedb, xmlreader, xmlrpc, xmlwriter, xsl, zip, clos_ssa
+-------------------------------------+---------+--------+
| Flarum Extensions                   |         |        |
+-------------------------------------+---------+--------+
| ID                                  | Version | Commit |
+-------------------------------------+---------+--------+
| flarum-flags                        | v1.6.1  |        |
| flarum-approval                     | v1.6.1  |        |
| flarum-subscriptions                | v1.6.3  |        |
| flarum-tags                         | v1.6.1  |        |
| flarum-suspend                      | v1.6.1  |        |
| fof-follow-tags                     | 1.1.7   |        |
| flarum-lock                         | v1.6.1  |        |
| flarum-likes                        | v1.6.1  |        |
| flarum-markdown                     | v1.6.1  |        |
| zerosonesfun-up                     | 1.0     |        |
| zerosonesfun-expired-posts          | 0.4     |        |
| v17development-seo                  | v1.8.0  |        |
| the-turk-nodp                       | 1.0.1   |        |
| sycho-advanced-extension-categories | v0.1.3  |        |
| ianm-gravatar                       | 0.2.0   |        |
| fof-sitemap                         | 1.0.3   |        |
| fof-polls                           | 1.3.0   |        |
| fof-nightmode                       | 1.5.1   |        |
| fof-linguist                        | 1.1.0   |        |
| fof-impersonate                     | 1.1.0   |        |
| fof-doorman                         | 1.1.1   |        |
| fof-byobu                           | 1.1.8   |        |
| fof-best-answer                     | 1.2.4   |        |
| flarum-sticky                       | v1.6.1  |        |
| flarum-statistics                   | v1.6.1  |        |
| flarum-mentions                     | v1.6.3  |        |
| flarum-lang-french                  | v4.6.0  |        |
| flarum-lang-english                 | v1.6.0  |        |
| flarum-emoji                        | v1.6.1  |        |
| flarum-bbcode                       | v1.6.0  |        |
| extiverse-mercury                   | 0.2.0   |        |
| datitisev-backup                    | 1.0.2   |        |
| clarkwinkelmann-mailing             | 1.0.0   |        |
| clarkwinkelmann-lock-likes          | 1.1.1   |        |
| clarkwinkelmann-group-invitation    | 1.0.2   |        |
| clarkwinkelmann-emojionearea        | 1.0.0   |        |
| blomstra-fontawesome                | 0.1.5   |        |
| askvortsov-rich-text                | v2.1.7  |        |
| askvortsov-moderator-warnings       | v0.6.1  |        |
| askvortsov-markdown-tables          | v1.2.1  |        |
| askvortsov-checklist                | v1.3.1  |        |
| antoinefr-online                    | v1.0.1  |        |
| acpl-mobile-tab                     | 1.1.1   |        |
+-------------------------------------+---------+--------+
Base URL: https://lepointdarret.com/public
Installation path: /home/accolade/lepointdarret.com
Queue driver: sync
Session driver: file
Mail driver: mail
Debug mode: off

Chromium blocks insecure content be default. Check your browser console.

If that image was served from an HTTPS url, it would show just fine in Chrome as well.

This is not a Flarum issue. Chrome has deliberately set this behaviour to help protect its users.
Read more about it here: https://blog.chromium.org/2019/10/no-more-mixed-messages-about-https.html

The image URL that you're trying to 'embed' is not encrypted with the "HTTPS protocol". That's why Chrome is forcing the image to be re-directed to HTTPS. Unfortunately, the website (where the image is located), is not correctly set-up with HTTPS so chrome returns nothing.

For example, if your image is located here:
http://ThirdPartyWebsite.com/img.jpeg

Chrome is forcing the website to:

**https**://ThirdPartyWebsite.com/img.jpeg - There's no such image located at this address

Here's the error confirming this:

There are workarounds for the end-user but I don't recommend it:
https://stackoverflow.com/questions/18321032/how-to-get-chrome-to-allow-mixed-content

    Wellwisher

    You are absolutely right. Not seeing the URL in edit mode was throwing me off. It seems that activating the FoF Secure HTTPS extension improves my situation.

    Well, now I activated the FOF Secure HTTPS extension, and even after making a new post that refers to a copy of those files residing on my flarum server, in a subfolder of the Public folder, images just do not want to display (now across chrome, firefox and safari). I just do not understand. Here is the post where I pointed to the images on my server: https://lepointdarret.com/public/d/44-logo-pour-le-forum/12

    Thanks for any information that can let me resolve this issue.

    If I should post this in the FOF Secure HTTPS thread instead, please let me know.

    With the FOF Secure HTTPS extension installed, seems the images are returning a 403 error (see below).
    Error code:{"errors":[{"status":"403","code":"permission_denied"}]}

    Interestingly, this error is similar to @neko 's post on the 'Secure HTTPS' by FriendsOfFlarum page here.
    Github states the bug was patched.

    @blueCamel Can you confirm what version of the 'Secure HTTPS' you're using? The version should be v1.1.0. If it is, raise the issue on the extension page. If it's not the correct version, update the extension.

      Wellwisher

      Thanks for looking into this. v1.1.0 is what I am running, so I will head over to the extension page. Thanks again for your assistance with this.