This is a migrated thread and some comments may be shown as answers.

Bing maps blocked under https on chrome and FF

3 Answers 123 Views
Map
This is a migrated thread and some comments may be shown as answers.
ITServices
Top achievements
Rank 1
ITServices asked on 08 Aug 2014, 01:25 PM
Hello guys, I have been working on an application using kendo maps, and everything went smooth till I tried to publish it into an https website. My map have two layers, the first one works perfectly but the one with Bing Maps never download the tiles.

This is my code:

 @(Html.Kendo().Map()
            .Name("mapwrapper")
            .Center(0, 0)
            .Zoom(2)
            .MaxZoom(16)
            .MinZoom(6)
            .Controls(controls=> controls.Navigator(false).Zoom(zoom=>zoom.Position(MapControlPosition.TopLeft)))
            .Layers(layers =>
            {
                layers.Add()
                    .Type(MapLayerType.Tile)
                    .UrlTemplateId(Url.Action(null, "Tiles") + "?z=#= zoom #&x=#= x #&y=#= y #")
                    .Subdomains("a", "b", "c");

                layers.Add()
                   .Type(MapLayerType.Bing)
                   .ImagerySet(MapLayersImagerySet.AerialWithLabels)
                   .Key("ApeI4THhSxCEqiGhrt4bEat9QIC_gCz8XXXXXXXXXXXXXXXX").Opacity(0);

            })
                .Events(events => events
                    .PanEnd("panEnd")
                    .ZoomStart("clearCanvas")
                    .ZoomEnd("zoomEnd")
                    .Click("onMapClick")
                    .ShapeCreated("onShapeCreated")
            )

I have been inspecting the Javascript console on Chrome and shows this error:

The application was loaded over HTTPS, but ran insecure content from 'http://dev.virtualearth.net/REST/v1/Imagery/Metadata/aerialwithlabels?outpu…z8ZHbGFu2qwIDypA4lEwRnAi8a_k7MvxwD&callback=bingTileParams&_=1407503550662': this content should also be loaded over HTTPS.

It works on Internet Explorer but not on Chrome and Firefox, last versions.

Do you know how could I fix this problem?

Thanks.

Best Regards.

3 Answers, 1 is accepted

Sort by
0
T. Tsonev
Telerik team
answered on 08 Aug 2014, 01:45 PM
Hi,

Thank you for reporting this problem. We'll get it fixed for the internal builds, but for the moment you can use the following workaround:
<script>
      kendo.dataviz.map.layers.BingLayer.fn.options.settingsUrl =
       "//dev.virtualearth.net/REST/v1/Imagery/Metadata/#= imagerySet #?output=json&jsonp=bingTileParams&include=ImageryProviders&key=#= key #";
</script>

Place it after the Kendo scripts are included on the page, but before the Map widget.

As a token of gratitude for your involvement your Telerik points have been updated.

Regards,
T. Tsonev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
ITServices
Top achievements
Rank 1
answered on 08 Aug 2014, 02:18 PM
Thanks, I appreciate, you will take this into account for future versions.

Your solution actually fixed the problem on Chrome, but is still not working on Firefox, anyway for me is enough with Chrome.

Thanks a lot for your quick answer.
0
T. Tsonev
Telerik team
answered on 11 Aug 2014, 12:47 PM
Hi,

Thanks for the heads-up. I've identified and fixed a couple of additional issues.
This should take care of Firefox and any mixed-content warnings.

We'll upload an internal build today with all fixes included.
Apologies for the caused inconvenience.

Regards,
T. Tsonev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Map
Asked by
ITServices
Top achievements
Rank 1
Answers by
T. Tsonev
Telerik team
ITServices
Top achievements
Rank 1
Share this question
or