Download
We're evolving to serve you better! This current forum has transitioned to read-only mode. For new discussions, support, and engagement, we've moved to GitHub Discussions.

No style with https in github pages

  • #6330
    Avatar photo[anonymous]

    Hello,

    I use Github Pages to host a small static site created with Publii. This site is visible at http://myrealbook.vintherine.org/. For a static site that does not ask for any login, without contact page and allowing no comment I did not find useful to worry about HTTPS.

    The problem is that if the address is forced in https the page is displayed but without any style. This is for example the case with Firefox in private window (even if the option “Do not activate https mode only” is checked).

    Do you have a solution or suggestion?

    Thanks in advance

    #6331
    Avatar photo[anonymous]

    OK, the problem is the stylesheet url in the page

    <link rel=”stylesheet” href=”http://myrealbook.vintherine.org/assets/css/style.css&#8221;

    when I manually change (within github) for href=”//myrealbook….” without http: it’s ok but the problem is the same with pictures and it’s not really a good solution

    I tried “relative URLs” in the Server parameters in Publii but after synchronization my web site was not found

    I tried “https” for the website URL in the same Server parameters without result : the link rel=”stylesheet” was always set to http and not https as expected

    Thanks in advance for your help

    #6352
    Avatar photo[anonymous]

    Hi,

    For me your website is loading properly via https – the protocol change to HTTPS most probably fixed your issue but there is always a small delay between deploy and changes visibility on Github

    #6359
    Avatar photo[anonymous]

    Hi Tomasz, thank you for your answer. Yes I finally switched into https in the Publii’s Github Page setting and checked the “enforce HTTPS” option on github page. Now everything works perfectly.