Jump to content

[Solved] Stores block not working after 1.4.1 upgrade !


Recommended Posts

I found the error: is inside classes/Tools.php

The function addJS() doesn't like to load external javascript files (in stores case, the google API js from google website).

There are 2 temporary alternative solutions:

1.Open classes/Tools.php and comment lines from 1340 to 1344 (from $url_data = parse_url($file); to unset($js_uri[$key]);)

2.Download Google API js from this link and save it to themes/prestashop/js/googlemaps.js, then open controllers/StoresController.php and change line 201 from Tools::addJS('http://maps.google.com/maps/api/js?sensor=true'); to Tools::addJS(_THEME_JS_DIR_.'googlemaps.js');

Link to comment
Share on other sites

I found the error: is inside classes/Tools.php

The function addJS() doesn't like to load external javascript files (in stores case, the google API js from google website).

There are 2 temporary alternative solutions:

1.Open classes/Tools.php and comment lines from 1340 to 1344 (from $url_data = parse_url($file); to unset($js_uri[$key]);)

2.Download Google API js from this link and save it to themes/prestashop/js/googlemaps.js, then open controllers/StoresController.php and change line 201 from Tools::addJS('http://maps.google.com/maps/api/js?sensor=true'); to Tools::addJS(_THEME_JS_DIR_.'googlemaps.js');


Good job! Easy fix.. #1 would probably be the better long term fix IMHO. Could be wrong though since I'm not that good at JS.
Link to comment
Share on other sites

Hi guys

I found the fix -

in Tools.php comment out the 2 lines after //check if js files exists

// check if js files exists
// if (!file_exists($file_uri))
// unset($js_uri[$key]);



Lines 1342-1343, google maps seems to work again.

Also remember to delete the compiled files in smarty folder

Please looks at this site for more info:
http://forge.prestashop.com/browse/PSCFI-1602

Hope that works

Link to comment
Share on other sites

  • 2 weeks later...

Hi guys!

I followed the different steps of this thread about google maps.

I had no maps on my page, that's why i followed those steps, but now have nothing anymore. Blank page with store.php !!

What do I have to do? please help me because I really don't now what happens :s

Prestashop version 1.4.1

regards

Link to comment
Share on other sites

  • 2 weeks later...

While following the solutions offered here in this thread i managed to get the google map show up in version 1.4.1, but the shop doesn't show up on trhe map. I downloaded the svn version of tools.php as suggested to solve the problem but that didn't work.
Anyone found a solution?

Link to comment
Share on other sites

It's ok now it works...

Now can someone tell any solution to fix google maps on last version Prestashop 1.4.1 ?

cheers


there is no solution to fix this bug in the latest version. (IMHO)

you may downgrade your shop to 1.4.0.17 or wait for the next version 1.4.2.0
I think it will rolling out soon.
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...