I'm not sure what has happened but the leaflet map has just completely disappeared. The beta 3 version works perfectly, however now that I've upgraded (the same issue occurs on 1.0) I have nothing where the maps used to be. When I inspect the html, there is just nothing in there where map used to be.

I am using views with ip_geoloc and the longitude and latitude fields are coming from the location module. I've created the same issue over at Leaflet here https://drupal.org/node/2189937. Really hoping there is a fix for this.

Comments

rdeboer’s picture

Hi kafmil

Use IP Geolocation Views & Maps 7.x-1.24 or 7.x-1.x-dev with Leaflet 7.x-1.1 or Leaflet 7.x-1.x-dev.
Use Leaflet JS 0.7.1 or 0.7.2 (note the folder structure, check the Status Report page, admin/reports/status).

If you use Leaflet More Maps or Leaflet MarkerCluster, also use the latest official or 7.x-1.x-dev versions (and latest version of Leaflet.MarkerCluster JS library).

See https://drupal.org/comment/8344335#comment-8344335.

Rik

rdeboer’s picture

Assigned: Unassigned » rdeboer
Status: Active » Fixed

I checked the above configuration just then and it all works for me.
Rik

prezaeis’s picture

Hi
Im having the exact same problem, i just get a div with nothing inside. I just upgraded all my modules to the latest dev version for the following (IP Geolocation Views, Leaflet, Leaflet More Maps and Leaflet Cluster)
I also have the latest libraries and no errors on the report page

What is going wrong ?

rdeboer’s picture

Any errors in the browser console?

prezaeis’s picture

Well, in Chrome i can see the following errors:

Consider using 'dppx' units instead of 'dpi', as in CSS 'dpi' means dots-per-CSS-inch, not dots-per-physical-inch, so does not correspond to the actual 'dpi' of a screen. In media query expression: only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min-resolution: 144dpi)

event.returnValue is deprecated. Please use the standard event.preventDefault() instead.

In firefox using Firebug and enabling ALL error messages i can see LOADS of CSS errors, but 4 of them seem to be JS errors, however when in firebug i click on ERRORS i dont see anything, only when i select ALL i see these:

Unknown property 'zoom'. Declaration dropped.
...#000;cursor:default;white-space:pre;zoom:1;}html.js input.form-autocomplete{back...

Unknown property 'box-sizing'. Declaration dropped.
box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;p...

Use of getPreventDefault() is deprecated. Use defaultPrevented instead.
...h=h.slice(c.length),c.type=g,c.matches=d);if(!c)break}return b?h.length:h?bc.err...

Error in parsing value for 'background'. Declaration dropped.
-webkit-linear-gradient(left, #000, #fff)

rdeboer’s picture

These errors don't seem to have anything to do with maps.
Are you using Leaflet JS 0.7.2 with latest Leaflet.markercluster JS?

prezaeis’s picture

yes they are both the latest, i even tried older versions. its very strange.
is there another way i can diagnose what the problem is?

rdeboer’s picture

You have of course run /update.php and hard-refreshed browser cache?
To isolate the issue, maybe disable Leaflet More Maps, IPGV&M and Leaflet MarkerCluster.
Just have Leaflet (you need to re-save your View).
See if that works. Then add the other modules one by one.

I'm running with the latest official versions of all these modules (these came out yesterday and are pretty much identical to the dev snapshots) and it all works fine for me. Not a single error. All 26 maps working fine. With clustering too....

prezaeis’s picture

the leaflet map itself actually works fine, even with the other modules on, so i think the problem lies with one of the other modules, the marker cluster and more maps also work fine with the leaflet map, which makes me think its the IP Geo module... might be conflicting with something else on the site? but then why isnt there any errors

rdeboer’s picture

@prezaeis:
Thanks for the feedback. That's a worry....
Yes what you say makes sense. But at the same time I can't reproduce it on my system, as I'm running the same setup as you and I don't have any issues....
Have you tried switching to "Map (Google, via IPGV&M)" ?
You can also switch on debug info at admin/config/system/ip_geoloc. Type your username into the box titled: "Detail execution progress with status messages"
Finally, the theme could potentially have an effect. When you switch to core Bartik, does that make a difference?
It's not this, is it: https://drupal.org/comment/8417189#comment-8417189
Other than that, if there are no JS errors caused by other modules that stop the execution of IPGV&M JS, I don't know.
Rik

prezaeis’s picture

Hia

Thank you for the reply.
OK i changed the theme to the Batrik theme and it still doesnt work, however this weird error message is showing up


Warning: file_get_contents(): https:// wrapper is disabled in the server configuration by allow_url_fopen=0 in drupal_build_js_cache() (line 4956 of /home/administrator/public_html/includes/common.inc).


Warning: file_get_contents(https://maps.googleapis.com/maps/api/js?sensor=true): failed to open stream: no suitable wrapper could be found in drupal_build_js_cache() (line 4956 of /home/administrator/public_html/includes/common.inc).

Turning on the debug mode, i dont see any errors, just this:


IPGV&M: last reverse-geocode request was 1.0 s ago.
IPGV&M: next update in 59 seconds (if not on excluded page).
IPGV&M: last reverse-geocode request was 13.8 s ago.
IPGV&M: next update in 46 seconds (if not on excluded page).

Does that error message mean anything?

prezaeis’s picture

I cant believe this. The link you provided, that was the problem!!! I unticked the 'use site templates' box and it works,

WOW, thank you so much, im really sorry for the hassle too. thank u thank u

rdeboer’s picture

Great!
So you are using a distribution? Or did you tick that box yourself? For what reason did you need it ticked?
If it is a distribution profile you are using, then I'd like to add that to the documentation of the module.
Rik

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.