Jump to content

[Solved] Product gallery images not working after hosting switch and upgrade


kinetik

Recommended Posts

Hi, I've just switched my hosting provider to Web Hosting Hub, since I'd seen they were a Prestashop preferred vendor awhile ago. 

 

The switch over wasn't easy and now that I've finally gotten it mostly working, there's still a few things that aren't quite right. I've searched for this info and can't find an answer anywhere. 

 

Basically the image gallery on the product pages isn't working. The cover image and the thumbnails show up but when you click on a thumbnail it doesn't switch out the main image and hovering over the large image doesn't magnify it anymore.

 

I suspect that the javascript isn't working properly but I can't seem to find any error messages that would point to any clue. The thumbnail slider arrows work and the thumbnails slide and highlight their borders as usual. The only thing that I notice is that there's a "js_def" in the top left-hand corner of my site now and I imagine this means some JS is undefined. 

 

When I toggle the CCC settings in the Performance tab, the javascript will stop working altogether. I've cleared cache several times, both by the UI and manually, checked the browser console for errors (none), and just about anything else I could think of or find in any forums. I did check and there is a products.js file, so I know it's not missing.

 

I have't modified the default template, I only altered the colors and images — so I'm really not sure where any code could be going wrong.

 

I upgraded Prestashop using the 1-click upgrade after switching hosts, thinking it would possibly fix any of the initial switching errors but that didn't fix anything. I could really use some ideas on what to try next.

 

See attached images for a visual on what's going on. The site is downunderhi.com

 

No errors in the configuration info

post-1305291-0-96088100-1472161401_thumb.png

 

Thumbnail highlights but main image doesn't change

post-1305291-0-99388800-1472161403_thumb.png

post-1305291-0-60222700-1472161405_thumb.png

 

js_def is printed in the upper left of my screen

post-1305291-0-16514500-1472161407_thumb.png

 

Thanks for your help!

 

 

Edited by kinetik (see edit history)
Link to comment
Share on other sites

Hi,

it seems there is a javascript problem with one of the javascript files. As i understood, if you enable CCC forjavascript then the js_def appears as text. That smarty variable should contain javascript variables included in the html code , and not to be displayed as text. try disabling the ccc for javascript and maybe for inline javascripts too. The images on the product page are not working since there is no javascript array of the images. 

Your add to cart button is not working either since there are missing javascript variables on the product page, and in module blockcart, the ajaxcart is enabled.

You can try and reset some of the modules, at least enable debug mode (DEV_MODE) from defined.inc.php file to check if there are some errors in any of the modules.

Regards, Leo

  • Like 1
Link to comment
Share on other sites

Thanks Leo, I'll give that a try and report back. I appreciate the help.

 

Edit—OK! That allowed me to see that I was apparently missing the layout.tpl from my theme. I'm not sure what happened to it, but I replaced it from my old server and voila! Thanks again for the help. All's good now!

Edited by kinetik (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...