0

You can define Bing Maps v8 JavaScript API to be loaded by appending the mkt parameter to the URL, for example: https://www.bing.com/api/maps/mapcontrol?callback=loadMapScenario&mkt=fr-fr

This translates the map as expected, but when using the translations module (Microsoft.Maps.Directions) the driving directions are not translated as they where when using the v7 of the Bing Maps JavaScript API.

In an example case I would expect the directions to be " Quitter James St en direction de 5th Ave...", when language is set to French, but instead I get english ones: "Depart 172nd Ave NE toward NE 80th St...". See online examples of how v7 translates directions, but v8 does not:

The behaviour of the platform has changed, but I am thinking this is just a bug. Is there a sensible way to change the translation variable in the REST API calls as the directions continue to be available in french as well as english, simply by modifying the c parameter in the URL:

1 Answer 1

0

The mkt parameter is not documented or supported in V8. It may change the language of some things but has issues. Not that there is no reason to set a language in V8 as it auto detects the users language and switches to their language automatically. s such, if a French speaking person visited your site, it would show French directions, which an English person would see English directions.

If you want to be able to override the language of the map, there will be an option to do this in the future, but it won't be the mkt parameter.

2
  • Thank you for your comment. I noticed has been a change to this, but that the old option should (and largely does) still work: social.technet.microsoft.com/wiki/contents/articles/… The issue I have with this automation is that I get mixed language results. If I am on a french site I would expect to get french results, even if my browser language is set to English. In fact, I have no clue how to get anything other than English. Probably by modifying browser settings since VPN from different locations always yields english.
    – Velmu
    Mar 22, 2017 at 6:19
  • As I said, the mkt parameter is not currently supported in V8. Thus the issue you are seeing. If you want, try pointing to the experimental branch. I believe the team is actively working on this.
    – rbrundritt
    Mar 23, 2017 at 1:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.