R2i DotNetNuke® Forum

R2i wants you to have the opportunity to ask questions, post reviews, help others or just rant and rave about DotNetNuke® or any of the R2i Modules and Skins. Our team spends hour upon hour, day after day, working on custom DotNetNuke® modules and services; please feel free to ask us anything.
 
Map fragmented in FireFox (2.0.0.7)
Last Post 08 Sep 2010 12:34 PM by jeklina11. 9 Replies.
Printer Friendly
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages Informative
oxnsUser is Offline
Basic Member
Basic Member
Posts:121

--
10 Oct 2007 01:37 PM  
Hi,

Had a map on a test site and I thought that it was working OK - just revisited my test site (with a view to making it live soon) and the map is 'blocky' - ie it only shows segments of the map in FF. Using IE (6.0.3790.3959) is shows and works just fine ;-O.

Also the map points don't work in FF - clicking just takes me off the map somewhere, but again fine in IE6.

Anyone got a pointer please - thoughts or ideas ??.

Was using 2.9.0 just upgraded to 2.9.3. Same issues on both.

Site can be seen at villa.oxns.net Information|Maps menu

Many Thanks

Graham
ewalkerUser is Offline
Basic Member
Basic Member
Posts:221

--
10 Oct 2007 01:58 PM  
Please try loading your map on a page with the generic dnn skin. It appear that the left navigation on your page is conflicting with the javascript that loads the map on the page.
Eric Walker - R2integrated
oxnsUser is Offline
Basic Member
Basic Member
Posts:121

--
11 Oct 2007 07:21 AM  
OK thanks for this - I'll take a look to see what is interacting then. Strange though that it works just fine in IE.

Graham
ewalkerUser is Offline
Basic Member
Basic Member
Posts:221

--
11 Oct 2007 01:43 PM  
No problem. Let us know how it works out.
Eric Walker - R2integrated
oxnsUser is Offline
Basic Member
Basic Member
Posts:121

--
08 Nov 2007 12:21 PM  
Been trying to get my head around this - as to why it should vary between browsers. I ended up posting a question to the Google API Forum and got the following response :

============================================================
> NB I am using a third-party tool to display the map (ie its not my own
> code), but before I can get them to fix it I want to understand what
> is going wrong :-O.

Where it's going wrong is that the map is not visible when it's
created. IE and FF handle this differently: often it's IE which has
problems. The API is being told that the map has zero size, so all
that's being loaded is the tile(s) which are necessary to show the
buffer-zone around your zero-size map. [The buffer zone is there to
allow map tiles to show when panning]

When you show your map, its <div> is suddenly expanded to full-size
but the API doesn't know about it, and thinks it's still of zero size.
Consequently it's only handling tiles within its calculated buffer
zone.

A relatively easy fix which works for both IE and FF is to add a
map.checkResize(); when it's resized by unhiding, but I can't find a
global variable in your code to use for "map", so I can't help with
where to add that statement.

===========================================================

I had already tried to hack your js file ad added :

eval('MAP' + ID + '.checkResize();');

near the end of goMap_Load()

But I guess this was the wrong place. It didn't barf but also didn't fix the problem :-((.

Any further thoughts maybe ??.

Many Thanks

Regards

Graham
ewalkerUser is Offline
Basic Member
Basic Member
Posts:221

--
08 Nov 2007 01:57 PM  
Hi Graham,

On quick way to execute javascript tests is using the URL portion of your browser window:

type:

MAPID[numberofyourmap].checkResize()

where [numberofyourmap] is the actually mapID
this should execute the javascript for you. This way, you don't have to edit the JS file while you're experimenting. Do you get get a JS error when you add the call to the goMap_Load() function?

-Eric
Eric Walker - R2integrated
oxnsUser is Offline
Basic Member
Basic Member
Posts:121

--
08 Nov 2007 02:04 PM  
Eric,

Nope - no error. In fact the page now has 2 alerts. If you'd care to take a look...

This is the code I added :

alert("Before checkResize()");
eval('MAP' + ID + '.checkResize();');
alert("After checkResize()");

Added just before the end of the If within the Try block...

Seems to make no difference...

Thanks

Graham
ewalkerUser is Offline
Basic Member
Basic Member
Posts:221

--
08 Nov 2007 03:37 PM  
When I called MAP196.checkResize(); from the URL, it resized the map area correctly. I think you need to call it later in the process. I see the javascript alert open on your page before I even see the map.

Try moving your call to checkResize() to a different function on the page. Off the top of my head, i'm not sure what that event would be.

Thanks,
-Eric
Eric Walker - R2integrated
oxnsUser is Offline
Basic Member
Basic Member
Posts:121

--
08 Nov 2007 04:55 PM  
Eric,

I think that we are on the right track and guess that the issue is being raised because the actual display of the map is maybe being deferred because of the other items on the page. So - it becomes a timing issue.

I have added a button which simply calls the resize function when a button is pressed (glad that this page is not yet 100% live ;-) - and that correctly resizes the page - redisplaying all map tiles BUT it is then centered wrongly - press the center button after this and you can see that the map then re-aligns itself. This seems to fit in with the failure reported regarding the buffer area - as that will be beyond the right and bottom of the module ??? - and its actually the bottom right tile which is displayed first.

SO - my guess is that because of these timing issues, we really need to ensure that the map calls are NOT being done before the page is fully displayed and sized correctly. Just forcing a resize after the event is a fudge (which is not 100% effective).

As I am now delving into the depths of the goMap module - I suggest that this is beyond my realm :-O - and is an issue with the module itself ??.

Incidentally another timing issue (could this be related) - I set the Initial delay value to 10000 (10 secs) so that there was a delay to allow all the other page elements to load befoe rendering the map ??. This setting has no effect in Firefox - but DOES indeed incur a 10 second delay in IE7.

Sorry but I suspect that I'll have to hand this problem back to bi4ce now :-(.

NB I can leave my site as is for the time being in case you want to do any further tests maybe ???. I can try out any potential fixes as well if required ;-)).

Many Thanks

Regards

Graham
jeklina11User is Offline
New Member
New Member
Posts:36

--
08 Sep 2010 12:34 PM  
Nice Post.
I like this post.
Very useful information providing.
SharePoint Consulting
You are not authorized to post a reply.

Active Forums 4.1
 

New York, NY • Baltimore, MD • Vienna, VA • St. Louis, MO • Seatle, WA • 410.327.0007 • info@R2Integrated.com

Bookmark & Share Bookmark and Share