Post by ccdsystems » Mon Jan 17, 2022 6:29 pm

When viewing the homepage the menu is an item list, the slideshow is all the photos just displayed one after the other on a flat html page. Its like no CSS is being loaded, however when any menu item link is clicked, or the home link is clicked, the home page that loads index.php?route=common/home displays the page normally again..

Install is 3.0.6.8 with php 7.3, installed via Installatron on Cpanel, upgraded from 3.0.3.2 -> 3.0.3.8
Problem began on 3.0.3.2, but was corrected using a backup, but after upgrading to 3.0.3.8 the problem came back.
Site is running the default theme, with no extensions, no modifications, no modules installed.

Newbie

Posts

Joined
Mon Jan 17, 2022 5:46 pm

Post by ADD Creative » Tue Jan 18, 2022 5:44 am

Probably and issue with the way your site's domain is defined in your config.php.

www.add-creative.co.uk


Expert Member

Posts

Joined
Sat Jan 14, 2012 1:02 am
Location - United Kingdom

Post by ccdsystems » Tue Jan 18, 2022 5:34 pm

Hmm.. It appears to be something to do with Chrome wanting a https site, but getting a http site, then calling scripts from the https site, which then triggers a security block. It doesnt allow the scripts to run and renders the broken page.

How did I come to this conclusion, I did an "inspect" on the page, saw 13 errors that referenced security issues because http site was calling https. I saw that when I inspected the menu bar css properties werent being applied.. A mouseover of the menu links revealed they pointed to the https version of the site, so when I clicked them it loaded the https version which then allows the scripts to run.. thus showing a good homepage.

I edited the config.php so that the https now points to https:// instead of http:// and the page seems to load more reliably now.. but still has little glitches like missing icons on the menu bar on the non secure version... they icons are displayed as squares.. heres the error I think is connected to the icons missing.
Access to font at 'website address/fonts/fontawesome-webfont.woff2?v=4.7.0' from origin 'website address' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.

But at least the page appears to be rendering now.. css and javascript are running again.. It seems the problem doesn't affect Edge.

Update: it appears the problem with the font thing is related to whether I load the page using www or not.. If I load from www.domain.com it doesnt block the font from loading, but if I load the page as domain.com (without the www.) it tries to load awesomefont from www.domain.com it thinks its loading from another site and blocks it.. (I assume its something similar to a cross-site scripting protection).. not sure what the fix for that would be.

Newbie

Posts

Joined
Mon Jan 17, 2022 5:46 pm

Post by ADD Creative » Tue Jan 18, 2022 6:08 pm

You need to make sure both HTTP_SERVER and HTTPS_SERVER are set to https:// in config.php. You also need to make sure that in htaccess you are redirecting www. or non-www. version of your domain to the one set in your config.

www.add-creative.co.uk


Expert Member

Posts

Joined
Sat Jan 14, 2012 1:02 am
Location - United Kingdom
Who is online

Users browsing this forum: No registered users and 43 guests