Post by mouser » Tue Dec 05, 2023 8:38 pm

Hi.
Several years back I installed OpenCart 2.1.0.1 which was the latest version at that time.
Since then it has run smoothly and without almost any kind of problems or technical issues, so I have seen no point in upgrading.
Server is currently running PHP 7.4
About a year ago some clients started to complain about malfunctioning and this is getting more frequent.

The problem is that some browsers (Chrome for example, Brave sometimes, desktop and mobile) do not display the shops main page correctly. It appears as there is no page formatting or theme present. All the products are displayed in one column under each other, there are no graphical details showing up (I use default theme), only product photos appear visible, no other graphical details can be seen. When clicking on a product, then the specific product page appears normal again.

With some browsers like Firefox, the site appears normal, everything as it should be, but other browsers do not show the main page as it should be, displaying only textual content and product photos which are all aligned in one long column.
Can someone please suggest, how to resolve this issue?
I have no great experience with OpenCart, only installed and configured it some 6-7 years ago, then forgot all about it because it was running excellently this far.
PS. admin panel is displayed correctly.

Thank you!
Last edited by mouser on Thu Dec 07, 2023 1:50 am, edited 1 time in total.

Newbie

Posts

Joined
Tue Dec 05, 2023 7:25 pm

Post by Cue4cheap » Tue Dec 05, 2023 11:01 pm

mouser wrote:
Tue Dec 05, 2023 8:38 pm
Hi.
Several years back I installed OpenCart 2.1.0.1 which was the latest version at that time.
Since then it has run smoothly and without almost any kind of problems or technical issues, so I have seen no point in upgrading.
Server is currently running PHP 7.4

Thank you!
To start: Downgrade PHP version under 7.4.

Next what errors are the logs?
Mike

cue4cheap not cheap quality


Expert Member

Posts

Joined
Fri Sep 20, 2013 4:45 am

Post by mouser » Wed Dec 06, 2023 12:41 am

Cue4cheap wrote:
Tue Dec 05, 2023 11:01 pm
To start: Downgrade PHP version under 7.4.

Next what errors are the logs?
Mike

PHP version was 7.1 actually, I only today switched to 7.4 and that did not make any visible difference in OpenCart behavior.
Switched back to 7.1 just now.
The error log does not reflect those occasions, when site is accessed and seen in non-correct appearance.
There are some lines in error log though:

PHP Warning: A non-numeric value encountered in /path/catalog/controller/product/manufacturer.php on line 175
PHP Warning: Division by zero in /path/catalog/controller/product/category.php on line 349
PHP Notice: A non well formed numeric value encountered in /path/catalog/model/total/shipping.php on line 24

Those kind of lines appear in error log.

Newbie

Posts

Joined
Tue Dec 05, 2023 7:25 pm

Post by paulfeakins » Wed Dec 06, 2023 7:01 pm

mouser wrote:
Tue Dec 05, 2023 8:38 pm
It appears as there is no page formatting or theme present.
This is usually an SSL problem.

Make sure both your config.php and admin/config.php files include the full https link everywhere and that your SSL Certificate is valid.

UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk


User avatar
Legendary Member
Online

Posts

Joined
Mon Aug 22, 2011 11:01 pm
Location - London Gatwick, United Kingdom

Post by SohBH » Wed Dec 06, 2023 8:37 pm

Given that the admin panel displays correctly, we can deduce that the HTML error lies within the frontend of the shop and some browser are more sensitive to the error.

View all extensions | Request custom work | Pricing | Contact Me


User avatar
Active Member

Posts

Joined
Mon Nov 02, 2020 12:01 am
Location - Malaysia

Post by ADD Creative » Wed Dec 06, 2023 8:45 pm

Are you redirecting to you prefered URL?

If you are using https://www.example.com/ in you config.php. You would need to redirect other forms to that URL in your htaccess. So that would be http://www.example.com/, https://example.com/ and http://example.com/.

www.add-creative.co.uk


Guru Member

Posts

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

Post by mouser » Thu Dec 07, 2023 1:47 am

Thank you all, who replied!
Problem got quickly solved by my web-developer friend.
Fix was quite easy - in config.php the line where https server was defined, letter "s" was missing after http :)

Newbie

Posts

Joined
Tue Dec 05, 2023 7:25 pm
Who is online

Users browsing this forum: Amazon [Bot], tdaubs and 64 guests