rstacruz / flatdoc

Build sites fast from Markdown
http://ricostacruz.com/flatdoc
2.68k stars 262 forks source link

Resources not loaded on HTTPS #27

Open mksplg opened 10 years ago

mksplg commented 10 years ago

When flatdoc is served using HTTPS, Firefox 23 and up and Chrome block the content with the message Blocked loading mixed active content "...".

Updating the links in the template solves most of the issues except the included font in theme-white's style.css.

rstacruz commented 10 years ago

Nice, anyone got a PR for this?

mksplg commented 10 years ago

The resource links would need to be changed to github's raw URLs, e.g. https://raw.githubusercontent.com/rstacruz/flatdoc/gh-pages/v/0.8.1/flatdoc.js as links currently used in the template are redirected to http://ricostacruz.com which does not support https.

Unfortunately, ghbtns.com used in the template also does not support https yet, see https://github.com/mdo/github-buttons/issues/61.

rstacruz commented 10 years ago

Oh, right. Forgot about that — gh-pages doesn't support HTTPS.

However, IIRC GitHub was pretty clear on not using https://raw.githubusercontent.com on production sites. Perhaps there isn't a good way around this afterall, unless you host it yourself.

mksplg commented 10 years ago

You're right, https://raw.githubusercontent.com serves everything with content-type text/plain.

Wouldn't https on gh-pages work if http://ricostacruz.com supported it or is that not supported by the redirect? At least if the page is accessed with https://user.github.io/repository without redirects, https works fine.

rstacruz commented 10 years ago

Google Fonts is now loaded via HTTPS. c1dbf23

rstacruz commented 9 years ago

rawgit.com offers a free CDN for git repos, and it support HTTPS. You should be able to use this URL:

https://cdn.rawgit.com/rstacruz/flatdoc/v0.8.6/flatdoc.js