Sage CRM Mapping Component Blank Map in My CRM

So, we are running Sage CRM 7.2 and are currently testing out the mapping component in our test environment.

The install appears to process without any errors but when going to My CRM and the Map Tab their is just a pin on a blank map. Has anyone got a fix for this issue?

One possible issue is the version, I can find downloads for 7.1 and 7.3 but nothing for 7.2, is there a recommended version for 7.2?

Last few lines of the ewaresystem.log show

May 7 2015 10:15:28.665 13708 25100 1 Wrong keys request: [SID=5138765646279&Act=160&Mode=40&CLk=T&Key-1=21&Key0=7&Key1=2312&Key2=5689&Key7=1027]
May 7 2015 10:15:28.805 13708 25100 1 Wrong keys url: [/crm_test/eware.dll/Do?SID=5138765646279&Act=164&Mode=1&CLk=T]
May 7 2015 10:15:28.805 13708 25100 1 Wrong keys: [21,1,2312,5685,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,]
May 7 2015 10:15:28.805 13708 25100 1 Wrong nokeys: [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,]
May 7 2015 10:15:28.837 13708 25100 4 EndUserAction,User,Action,Time 1 160 499
May 7 2015 10:15:30.303 13708 22832 4 StartUserAction,User,Action 1 6030
May 7 2015 10:15:30.366 13708 22832 4 EndUserAction,User,Action,Time 1 6030 63
May 7 2015 10:15:30.740 13708 22160 3 CoeWareBaseInit,QueryString SID=5138765646279&Key-1=21&Key0=1&Key1=2312&Key2=5685&J=xtmp_maps/mapstab.asp&T=Company
May 7 2015 10:15:31.146 13708 22160 3 CoeWareBase,Time 406


Your help is greatly appreciated!

  • 0

    Hi,

    This works OK for me on 7.3a and 7.2h. The logs you're posted aren't really relevant - the "wrong keys request" messages are red herrings, removed in a later patch.

    I'd be looking at what happens to your requests to *.tile.openstreetmap.org. This can be done using Fiddler. I suspect that they're being blocked by a proxy or similar.

    I've been speaking with the UK support team in Winnersh regarding the case you logged for this - they'll be in contact with a few other things to check.

    Thanks,

    Rob

  • 0

    Rob, thanks, I've found that the issue, at least for us, is being caused by SSL being set to required in IIS. I don't particularly want to disable this setting, is it something that we can update in the configuration files?

    Thanks,

    Brad

  • 0

    Same Problem - how can I disable SSL?

  • 0

    Open IIS > Navigate to your CRM site in the left hand pane -> SSL should be one of the icons in the central pane -> Double click and uncheck "Require SSL".

    Just be aware though that this is not good for your sites security...

  • 0

    "Require SSL" is unchecked - the map doesn`t work

  • 0

    I would suggest uninstalling the component, double checking the pre requisites and making sure you have your Internet Explorer compatibility view settings correct form your version of Sage CRM and then reinstalling.

    I performed these steps and the component then worked fine. If this does not resolve the problem I would log the issue with your local support team so they can investigate further.

  • 0

    Hi folks,

    Apologies, I was looking at the dashboard rather than the Maps tab when I was checking this issue out. Really sorry about that guys - totally missed the issue.

    There's a good few errors here - I can get the mapping component to mostly-work on the Maps tab by having a fool around with it, but it's by no means 100% fixed.

    I'm raising this case to the development team for a permanent fix.

    For interest, here's what I've done as a workaround:

    1: In MapsTab.asp, append the following to the html variable before it's written out using CRM.AddContent:

    That goes in about line 251. Basically, there were a number of unclosed tags in the screen HTML, which caused JS errors.

    2: There's been some sort of change around how the heights of divs are being worked out - this is resulting in the div that's used to render the map (mapdiv) not being given a size. This results in you not being able to see the map (though it's there... allegedly).

    I've worked around this by setting the width and height of the mapdiv element in MapsTab.asp.

    Now, lines 234 to the end of my MapsTab.asp look like this:

    html += '

    ';

    html += '
    ' + (!companyMapped ? 'style='display:none;' ': '') + '>';

    html += '" ? (companyId ? "Company" : "Lead") : "Company") + '.png" style='position:relative;left:-16;top:-56' />';
    html += '';
    html += '
    style='height:100%;width:100%'>
    ';

    html += '';
    html += '';
    html += '';
    ' + mapOptions + '

    html += '';
    /*
    html += '';

    html += '
    ';

    html += '
    ';

    html += '';
    html += '';
    */
    html += '';
    html += '';
    CRM.AddContent(html);

    Response.write(CRM.GetPage());

    %>

    The two fixes are highlighted in yellow.

    This definitely doesn't fix the layout issues, but should get the tab working again.

    I suspect that the browser had been massaging these errors out of existence, but that the pages are no longer working since the frameset removal in v7.2.

    Kieron Moran (of this parish) has put together a modified MapsTab.asp, and has kindly made it available here:

    https://community.sagecrm.com/partner_community/f/19/t/11714.aspx

    I haven't tested it, but I can see that he's included my second fix.

    With regards to the HTTPS thing - the issue seems to be around the display of mixed content in the browser. I've removed my HTTP binding, and it works so long as I select "Show all content" to the "Only secure content is displayed" prompt.

    The issue here is that the OpenLayers.js library that we're downloading, as well as the content used isn't available over HTTPS. This is a bit of a pain. I won't go into more detail, but there's explanations of why this is the case, and what possible workarounds might exist available here:

    http://gis.stackexchange.com/questions/83953/openlayer-maps-issue-with-ssl

    Hope this helps.

    All the best,
    Rob

  • 0

    In regards to the SLL mixed content issue, this can be resolved by installing the entire OpenLayers release locally, and by modifying a javascript file to use protocol-relative links.

    First:

    CRM 7.3 uses OpenLayers 2.x, so you will have to download that entire stable release (~11MB) off their website: http://openlayers.org/two/

    Once that is done, unzip the release into your CRM/WWWRoot/CustomPages/xtmp_Maps/OpenLayers directory (create the OpenLayers directory).

    Edit the MapsTab.asp file at around line 84-85 to include:

    // CRM.AddContent('');

    CRM.AddContent('');

    What we are doing here is commenting out the local OpenLayers.js file, and adding the entire OpenLayers build that we downloaded.

    Second:

    You will need to open up the MapsTab.js file (under CustomerPages/xtmp_Maps) and modify all http links to use protocol-relative links.

    Protocol-relative links look like "//community.sagecrm.com" instead of "">https://community.sagecrm.com"

    There are 2 references that you will need to change (~lines 46 and 60):

    function nominatimLookup(addr) {

    $.ajax({

    url: '//nominatim.openstreetmap.org/search', ...

    }

    function amenityLookup(...) {

    addScriptTag('//nominatim.openstreetmap.org/search?q=' + type + '&fo ...

    }

    Now maps should work under SSL.

    Cheers,

    Serge.

  • 0

    Also, in its current state, Rob's fix will not work correctly.

    Line:

    html += '

    ';

    should be:

    html += '

    ';

    There needs to be double quotes " for the style= field. The single quotes will break that string literal.

    Otherwise, all looks good.