My favorites | Sign in
Project Home Issues
New issue   Search
for
  Advanced search   Search tips   Subscriptions
Issue 9004: Bug: Javascript error - https://maps.googleapis.com/maps-api-v3/api/js/23/2/intl/en_gb/onion.js
41 people starred this issue and may be notified of changes. Back to list
Status:  NeedsMoreInfo
Owner:  [email protected]


Sign in to add a comment
 
Reported by [email protected], Dec 8, 2015
My application, developed in Visual C++ 2013, loads a javascript file into a CHtmlView object. It worked perfectly well until it recently started displaying the error message https://maps.googleapis.com/maps-api-v3/api/js/23/2/intl/en_gb/onion.js.

To ensure that this error had nothing to do with my application or javascript file, I recreated the problem using Microsoft's sample Internet Explorer project (https://msdn.microsoft.com/en-us/library/ms177540(v=vs.90).aspx) simply modifying it to open one of Google's sample map javascript files (https://developers.google.com/maps/documentation/javascript/examples/map-simple). I've attached the modified project.

When the exe is run the map is displayed correctly but after a minute or two of zooming and mouse movements an error dialog is displayed with the script error.

Also, perhaps or perhaps not related, even though I modified the javascript file to call version 3.22 of the Google Maps API it always seems to be using 3.23!

Ideas?

Thanks

Alex
Dec 8, 2015
Project Member #1 [email protected]
(No comment was entered for this change.)
Status: PendingFurtherReview
Dec 8, 2015
Project Member #2 [email protected]
Hey thanks for your report, could I ask some follow up questions?

1) Could you please show how you're trying to call version 3.22 ?
e.g. if I change the call in your html file to:
https://maps.googleapis.com/maps/api/js?key=AIzaSyBlmQ1dUBzQTIB7z-seimO2ZhngP_Hf_SQ&callback=initMap&v=3.22

it does load 3.22, what do you change, and what do you observe?

2) Could you please indicate your error message? I'm not quite sure how an URL is an error message, it's probably the file where the JS error comes out of, but what is the actual error?

Also can you distill your program to a simple map html where the error occurs? 
The GoogleMap.html in your zip file loads a map fine, I have no errors on the console.

Status: NeedsMoreInfo
Owner: [email protected]
Dec 9, 2015
#3 [email protected]
Hi, thanks for looking into the issues.

1. I've attached an html file that opens a map requesting version 3.22 and then displays the version (using google.maps.version) at the top. The version displayed is 3.23.2.

2. You need to run mfcie.exe in the release folder of the mfcie project. The map opens perfectly but if you then zoom into the Wollongong city a few times, drag the map around and move the mouse over the city for a while. After a minute or two the popup (see attached screen shot) should appear - be patient it doesn't happen after a consistent period  of time but always does eventually. I'm running it on Windows 10.

There's no point in just examine the html as it's the combination of the c++ program using CHtmlView and the html file that causes the problem.

Regards

Alex
Dec 9, 2015
Project Member #4 [email protected]
Your bootstrap request has  this in it: &v3.22
you'll need write &v=3.22 and you'll get 3.22 served.

I'm afraid we can't support a full c++ program, that wouldn't scale for us. For us to look into it we'll need to have a cut down html file, as that's what we actively support.

Maybe you describe certain features that you use that trigger it?
Can you keep cutting functionality out of your app till the error goes away and tell us which line of yours make us trip over?
Dec 9, 2015
#5 [email protected]
Ah, sorry, I must have been blind to the '=' character. Thank you for pointing it out.

It does appear that the test app fails when using 3.23 but works with 3.22.

As the app cannot only be defined by an HTML document and needs to be a mix of Microsoft and Google technologies we (and any other users of Microsoft's CHtmlView control) will have to remain on 3.22 unless the issue is resolved in future releases. Neither the Microsoft c++ project and the sample HTML document can't really be simplified any further so I'll have to leave it at that...
Dec 9, 2015
Project Member #6 [email protected]
Unfortunately version 3.22 will not be supported over the long term. It's our current release version, in a quarter will become the frozen version and in another quarter it will be phased out.

Your CHtmlView creates an embedded IE view, right? May I ask which version of IE this is using in your case?

This is helpful as a) we might be able to create this issue by loading your HTML version in a non embedded view for that version. and b) if it turns out to be an old unsupported version IE8 or older, you might be able to upgrade the version, and the error might be resolved?
Dec 9, 2015
#7 [email protected]
I have to point out that it's Microsoft's CHtmlView not mine. But, yes, it creates an embedded IE view. Looking at various documents it seems it defaults to IE 7 but can be encouraged to use later versions with registry entries. This link explains how and why 

http://weblog.west-wind.com/posts/2011/May/21/Web-Browser-Control-Specifying-the-IE-Version

I've tested the various options and can report the following with V3.23 -

Value 1B58 IE 7 - This starts ok but the onion message appears
Value 22B8 IE 8 - Displays a browser version not supported warning but no onion error
Value 270F IE 9 - Works perfectly
Value 2AF7 IE 10 - Onion error
Value 2EDF IE 11 - Onion error

I haven't tried all of these settings with v3.22 but it looks like IE 9 is the sweet spot!

Dec 9, 2015
Project Member #8 [email protected]
Is any of the IE10 or IE11 error messages more useful than "Script Error" ? At line 0, char 0?

knowing where this happens or what exactly happens would be very useful.

IE9 might be a nice work around for now, but knowing what happens might be able to help us to track down this for higher IEs.
Dec 10, 2015
#9 [email protected]
Just as an FYI, we are having the same problem. The popup error keeps popping up and makes the user just down the app via the manager and restarting in order to use it.
Dec 10, 2015
#11 [email protected]
No, the message is the same and therefore equally unhelpful.

If you wish to test it yourself I can email you the test exe and you can vary the script and IE version.
Dec 10, 2015
#12 [email protected]
Here is the error that locks everything on ours:

http://puu.sh/lQtDf/90a79da6fc.jpg


Dec 10, 2015
#13 [email protected]
kgolub - are you calling the script from within a CHtmlView as well or from within a browser?
Dec 10, 2015
#14 [email protected]
everything on our page is done with javascript within the browser.


Dec 10, 2015
#15 [email protected]
Great! Perhaps you could provide more details of your browser and the script to enable Google to resolve the issue. With any luck, it'll fix it for everyone.
Dec 10, 2015
#16 [email protected]
Since the error doesn't occur until mouse movement, here is the relevant code:

var callBackMapObjectMouseUp = function (mEvent) {
    mapObject.draggable = true;
    dragging = false;
}

var callBackMapObjectMouseMove = function (mEvent) {
    latlng2 = mEvent.latLng;
    console.log(mEvent);
    showRectangle();
}

var callBackMapObjectMouseDown = function (mEvent) {
    mapObject.draggable = false;
    latlng1 = mEvent.latLng;
    dragging = true;
    pos1 = mEvent.pixel;
}

var callBackRectMouseUp = function (data) {
    mapObject.draggable = true;
    dragging = false;

    var center = Rect.getBounds().getCenter();

    ZoomFactor = mapObject.getZoom();

    if (ZoomFactor < 25)
        ZoomFactor += 2;

    mapObject.setCenter(center);
    mapObject.setZoom(ZoomFactor);
    Rect.setMap(null);
    Rect = new google.maps.Rectangle({ map: mapObject });
    google.maps.event.addListener(Rect, 'mouseup', callBackRectMouseUp);
    latlng1 = 0;
    latlng2 = 0;
}

var callBackRectZoomOutMouseUp = function (data) {
    mapObject.draggable = true;
    dragging = false;

    var center = Rect.getBounds().getCenter();

    ZoomFactor = mapObject.getZoom();

    if (ZoomFactor > 6)
        ZoomFactor -= 2;

    mapObject.setCenter(center);
    mapObject.setZoom(ZoomFactor);
    Rect.setMap(null);
    Rect = new google.maps.Rectangle({ map: mapObject });
    google.maps.event.addListener(Rect, 'mouseup', callBackRectZoomOutMouseUp);
    latlng1 = 0;
    latlng2 = 0;
}
Dec 10, 2015
#17 [email protected]
I forgot the "showRectangle" :

function showRectangle(){
    if(dragging){
        if(Rect == undefined){
            Rect = new google.maps.Rectangle({ map: mapObject });
        }

        var latlngBounds = new google.maps.LatLngBounds(latlng1, latlng2);
        Rect.setBounds(latlngBounds);
    }
}
Dec 10, 2015
Project Member #18 [email protected]
The plot thickens! If you can provide an example that fails under a normal browser we can take it from there.

So would it be possible to attach the example as an HTML and specify under which browser it fails?
Or even better can you point at a jsFiddle?

I'm asking this because the example you have provided so far is not complete, it doesn't specify what mapObject is (I assume this is a google.maps.Map, but if so, how is it initialized?) what is the size of the div it ends up in? A real example would be greatly appreciated. 
Dec 10, 2015
#19 [email protected]
Picasa version 3.9.137 (build 81) for Windows has the same problem with its map window.  

I get a pop-up that says: 
"An error has occurred in the script on this page.
line: 0
Char: 0
Error: Script error
Code: 0
URL: http://maps.google.com/maps-api-v3/api/js/23/2/onion.js
Do you want to continue running scripts on this page?"

ScreenShot006.png
388 KB   View   Download
Dec 11, 2015
#20 [email protected]
  var mapOptions = { zoom: 15, printControl: true, center: new google.maps.LatLng(41.499495, -81.695409), mapTypeId: google.maps.MapTypeId.ROADMAP };
    mapObject = new google.maps.Map(document.getElementById("map_canvas"), mapOptions);

Dec 11, 2015
#21 [email protected]
geocoder.geocode({ 'address': address }, function (results, status) {
            if (status == google.maps.GeocoderStatus.OK) {
                mapObject.setCenter(results[0].geometry.location);

                var marker = new google.maps.Marker({
                    map: mapObject,
                    draggable: true,
                    animation: google.maps.Animation.DROP,
                    position: results[0].geometry.location
                });
                
            } else {
                alert('Could not locate the address for the following reason: ' + status);
            }
        });
Dec 12, 2015
Project Member #22 [email protected]
geocoder is also not defined.
Would it be possible to attach 1 large file  with everything together (or even better everything at jsfiddle) and mention which browser + version this throws the error? Much appreciated.

Dec 13, 2015
#23 [email protected]
i have the same problem.
Dec 14, 2015
#24 [email protected]
geocoder = new google.maps.Geocoder();

Dec 14, 2015
Project Member #25 [email protected]
#24

Would it be possible to attach 1 large file  with everything together (or even better everything at jsfiddle) and mention which browser + version this throws the error?

#23

Do you have the same problem in a webview as well? Or do you have a sample html file?
Dec 14, 2015
#26 [email protected]
Have the same problem

I make a hmtl file an them i show it Using Visual Fox

    THISFORM.oleIE.Navigate2('&file')

When i call the html file double clicking it, it open with the internet
Explorer without any problem


I have been using this code for a few Years, Start recieving these error few days ago.

i'm attaching a image with the problem and the HTML file.

Regards
Jorge

MiHtml.htm
1.2 KB   View   Download
Dec 14, 2015
#27 [email protected]
This is the image file with error. Before it was a wrong one.

Regards
Jorge
Onion Error.jpg
92.2 KB   View   Download
Dec 14, 2015
Project Member #28 [email protected]
Please make a jsfiddle that illustrates the problem in IE 10 and 11 *not* in a web view.
Dec 14, 2015
Project Member #29 [email protected]
FYI the attached file of #26 doesn't work because the

var map 

is defined in a function closure and referenced on line 18 outside that function closure.
Dec 15, 2015
#30 [email protected]
here is entire js file.......not all functionality is used.
Main.js
16.8 KB   View   Download
Dec 15, 2015
Project Member #31 [email protected]
Could you please attach the entire HTML file, which also has the DOM structure with the Map Div in it, and which version of the Maps API and jQuery you're using?

Also on which browsers (IE version) does this generate an error for you?
Dec 17, 2015
#33 [email protected]
I had the same issue and found a solution. I received the same error message (onion.js, line 0, char. 0) on a machine with Internet Explorer version 11. I tested the map on a machine with Internet Explorer version 8. The error message was different. This time line 25, character 37 of onion.js was the problem ('JSON is undefined'). A version of the Google Maps API had not been specified. I specified version 3.22 (&v=3.22). The error message no longer appeared. I then tried specifying version 3.23. The error message came back. From this I assume that not specifying the version gets you the newest version. The code in the web page probably needs updated to better agree with the newer version of the Google Maps API. Hope this is helpful.
Dec 17, 2015
Project Member #35 [email protected]
So we have introduced a JSON.parse in onion.js which explain why people get an Error on IE7. (Which is what webviews default to). Making the webview use IE9 (or higher) will resolve that issue and you'll get a support version. If this turns out to be the problem, I suggest to close this bug, as IE7 is really not a support version anymore.

I'm not able to reproduce any error on IE10 or IE11, and I'd still appreciate if anyone could post a reproducible example, everything in one file, DOM+JS everything included that can load it so I can debug it (a jsFiddle would be awesome and would guarantee that if I can reproduce it I'll look into it).
Unfortunately, I can't reproduce it by copy pasting different pieces together from different post with DOM snippets and bootstraps, and helper utility functions missing, nor can I really run untrusted executables which contain a webview (my apologies!).
Jan 12, 2016
#36 [email protected]
Steps in order to reproduce the problem with IE11 (Windows 7):
- Open http://www.a-rival.de/de/outdoor/gps-uhren/spoq#downloads
- Download "Trainingssoftware für SpoQ V1.89 vom 07.05.2015 (2.8 MB)" --> Setup_SpoQ_Training_Gym_Pro.exe
- Install Setup_SpoQ_Training_Gym_Pro.exe
- After opening the program click "Planning > Routes"
- In window "Planning" enter an address which will be centered in the map, and click "Search"
- Click at + in the map repeatedly and move the mouse after each click.
- After clicking 9 times you'll get an error window "Script Error" (URL http://ditu.google.cn/maps-api-v3/api/js/23/4/intl/de_ALL/onion.js )
Jan 12, 2016
Project Member #37 [email protected]
Like I explained in #35:

"nor can I really run untrusted executables which contain a webview (my apologies!)."

I really would like to take this own, but I really need to have a way to reproduce this on a webpage, as explained before.
Jan 12, 2016
#38 [email protected]
I encountered this problem today in a program I've written using the .NET WebBrowser control. I was able to resolve it by setting a value of 2af8 (IE11 mode) for my app in the FEATURE_BROWSER_EMULATION registry section as mentioned by Alex above. It is important to note that if you're debugging using Visual Studio you will also need to add an entry for the 'vshost' version of your application EXE as well for it to be detected properly.

Not having a FEATURE_BROWSER_EMULATION setting for your app will default it to IE7 mode. I can understand if Google does not want to support IE7. It would, however, be nice if the version check and notice for IE7 worked like that of IE8. That would likely attract the right attention more quickly.

But for those who want to repro this problem easily in Visual Studio it takes but a few simple steps (as Alex pointed out):
* create a new Windows Forms Application
* add a WebBrowser control to the form (it should fill the form)
* copy the "Javascript+Html" into a local html file from the sample at
      https://developers.google.com/maps/documentation/javascript/examples/map-simple
* set the Url property of the WebBrowser control to the name of the copied html file
* run the project, wave the mouse around over the form and generate the error

Feb 2, 2016
#39 [email protected]
We too confirmed seeing the Script Error 0, onion.js. Tried in both .NET 3.5 WebBrowser and .NET 4.6.1 WebBrowser control. Tried to use workaround of  FEATURE_BROWSER_EMULATION registry key but did not seem to help with either of the settings. One workaround I suggest to load the map is use Google Chrome in frame-less mode. 

"C:\Program Files (x86)\Google\Chrome\Application\Chrome.exe" --chrome-frame --window-size=800,600 --app="http://yourwebapp.com/map.html"


Feb 15, 2016
#40 [email protected]
Are there any news about the reported problem? Today the release 3.23 with this bug has become stable.
Feb 15, 2016
#41 [email protected]
I'm also getting this mistake as of today...it occurs the second after I go with my mouse over the custom drawn info object (the box conataining "Nova lokacija\LOGITRANS GMBH" text). This happens despite the fact that I call 
google.maps.controlStyle = 'azteca'; 
before I define a map object... 
mouseover.png
62.5 KB   View   Download
Feb 15, 2016
Project Member #42 [email protected]
Yes, version 3.23 has become stable.

There is clearly a problem, but so far we have not been able to reproduce it. I'd invite anyone to point us to a jsfiddle that demonstrates the problem. Please!
Feb 16, 2016
#43 [email protected]
Hello,
i created this jsfiddle as you ask: https://jsfiddle.net/4qrymm9g/1/ 

But you can't reproduce the problem in this manner, it works. The problem come out only if you save the code above in an html page on disk, and than call it from a client app, using for example .NET Windows.Forms.WebControl in my case. If it is useful, you can find attached a VB.NET project that reproduce the problem. If you don't have Visual Studio you can go to the bin\debug folder and call the compiled exe.
To fire the onion script error you have to zoom in and out a couple of time, move the map, and than stop the mouse arrow for about a minute. When you move again the mouse over the map the error come out.

I hope this is helpful.
Thank you.
CallMaps.zip
71.8 KB   Download
Feb 16, 2016
#44 [email protected]
Hi!

Since a couple of days, we had the same problem. We had read in other forums than the issue could be resolved changed the google maps' url parameters with v=3.22, but this workaround don't work fine...

We are used a webcontrol to show a google maps in a wpf application. 

Please any idea
Feb 16, 2016
#45 [email protected]
Version 3.22 works for me. The problem appeared with v3.23.
Feb 16, 2016
#46 [email protected]
The workaround works partially really. But sometimes, when we use a click event, the issue aprears again...
Feb 16, 2016
#47 [email protected]
Even WinDev projects that create a html disk file and then displays the maps in a custom control, fails.

The code below obviously brings back version 3.23 ( failing after about a minute with onion.js problem)when placing markers on the map.
//URL de l'API
WDCarteGoogleMaps.URL = "http://maps.google.com/maps/api/js?language=en&v=3";
 
Feb 16, 2016
#48 [email protected]
To the google people requesting a 'jsfiddle', etc.: I suspect you're only going to repro this if you can find older versions of IE to view it in, or do so from a Visual Studio project using a WebBrowser control. Since you don't trust other peoples VS projects that means creating one of your own. I and others have outlined the steps for that.

To those who claim the FEATURE_BROWSER_EMULATION fix does not work for them: I'd like to understand better, since it works for me. To emphasize, it's possible you may have to set UP TO FOUR registry entries to get this to work. There are TWO locations for entries, the '\Microsoft\' location and the 'Wow6432Node\Microsoft' location for 32 bit apps on 64 bit machines. While debugging you also need to add keys for your ".vshost.exe" as well as your ".exe". That's a total of FOUR KEYS to cover ALL the bases. Setting these keys to 0x2af8 works for me to get IE11.0 emulation. To make sure you've got it right, check the navigator.userAgent javascript property. It should contain the string "rv:11.0" to indicate IE11.0. If someone has done ALL this and still experienced the problem, that would be good to know.

More info about FEATURE_BROWSER_EMULATION at https://weblog.west-wind.com/posts/2011/May/21/Web-Browser-Control-Specifying-the-IE-Version

Feb 16, 2016
Project Member #49 [email protected]
Hi everyone,

Thanks for the jsfiddle. That helps. We understand now that the problems only appear inside a WebControl. We'll investigate.

I'm also keen to hear stories from people who ask the WebControl for the navigator.userAgent (and maybe document.documentMode ?). Then we can pinpoint which versions are affected.

It seems mystifying that a WebControl should be behave differently from a standalone IE browser !
Feb 16, 2016
#50 [email protected]
I just completed a test with all the FEATURE_BROWSER_EMULATION values documented at
https://msdn.microsoft.com/library/ee330730%28v=vs.85%29.aspx#browser_emulation. (This has not been updated since 2012 but it's the latest MS specification I found.)

I've attached a TXT file with the results including the userAgent strings. I found only the IE7 emulation to fail.

Note that the page I referenced in an earlier post shows some incorrect hex values for the correct decimal FEATURE_BROWSER_EMULATION values. Interestingly enough, when I entered those and other invalid values the userAgent string indicated the Edge browser!!

I hope this helps!
gmaps bug.txt
2.4 KB   View   Download
Feb 16, 2016
Project Member #51 [email protected]
In light of this information, I would really implore everybody to set the right FEATURE_BROWSER_EMULATION. The culprit is a JSON.parse which we have introduced, which IE7 doesn't have (but IE8 already does, so it's not hot of the press technology in anyway)

Dropping down a Maps API version is not really a solution, as the current Frozen version will be deprecated in a quarter.

If there is anybody who can reproduce the issue with a IE version higher or equal to 9, please provide this info!
Feb 19, 2016
#52 [email protected]
I have had reports from several of my sites around UK and Europe that even with the Feature_Browser_Emulation set to the specific values for the browser in use. They have reported this on IE9 and IE11 so far.
Unfortunatley, I don;t have the skills to provide you with and samples, I have no idea what jsfiddle files are or how to get you one.
All I want to do is point out that there is still a problem with embedded browser pages on IE9 and IE11.

thanks

Feb 24, 2016
#53 [email protected]
Evidence from my sites is increasingly showing that only IE11 is going to work. Nothing appears to make IE9 work. 
Anythng happening on a generic fix for this issue? All seems quiet since Feb 16th!

Thanks
Feb 24, 2016
Project Member #54 [email protected]
We believe ScottFerg56's comments #48 and #50 represent the solution to the problem.
Feb 24, 2016
Project Member #56 [email protected]
With requesting 3.0 instead of 3, you're getting our frozen version instead of the release version. That version will be deprecated somewhere in May.

Why not set the IE version?

If the IE version does not work, please verify this by actually writing out the resulting IE version into the DOM, so it's clear you actually got the version you thought you would get, as is pointed out in this thread, setting the IE version is not obvious.
Feb 25, 2016
#57 [email protected]
Just to echo #52 we too have set the Feature_Browser_Emulation (to ie11) but are still seeing intermittent issues; looking at the user agent string we are definitely utilizing IE11. Our user base has had this issue ongoing for a while now and are debating whether we drop the geocoding part of our app .

If there is any more info i can provide do let me know.
Feb 25, 2016
#58 [email protected]

Found this interesting link ... http://blogs.msdn.com/b/patricka/archive/2015/01/12/controlling-webbrowser-control-compatibility.aspx .. sharing with everyone on this thread.

Sounds like if Google team adds the Compatibility Meta-Tag on their side then all of our problems could go away. 

<meta http-equiv="X-UA-Compatible" content="IE=edge">.


Feb 25, 2016
Project Member #59 [email protected]
#58: <meta> tags are in the control of the developer that writes the web page using the Maps API
Feb 26, 2016
#60 [email protected]
#59 - Got it! It helps in my case. Added this to our webpage (in the head tag) and no more Onions :). Confirmed without on my Windows 10 Dev PC get script error, with it no error.

    <meta http-equiv="X-UA-Compatible" content="IE=edge">


Feb 27, 2016
#61 [email protected]
Just found this thread with same onion problem using IE11 in Webbrowser control on Access databse form, and #58 adding to html header fixes it for me too - thanks!
Feb 29, 2016
#62 [email protected]
#58 works for me. Same thing with registry key.

Thank you.
Feb 29, 2016
#63 [email protected]
works for me too
Mar 3, 2016
#64 [email protected]
I'm also suffering from the onion.js error using the visual studio webbrowser. Have tried setting the registry entries to emulate IE9, 10 & 11 double checking the changes have the correct effect with a javascript alert showing the navigator.userAgent. I still get the error. The only work around I have is fixing the google api version to &v=3.22. Once this version is depreciated I'm stuffed. Anyone have any further suggestions
Mar 3, 2016
Project Member #65 [email protected]
Re #64: Does it still happen with the <meta> tag. See comment #60.
Mar 15, 2016
#67 [email protected]
Re #64 Update for you, I found using the <meta> tag suggestions made no difference.
I went back and re-tried all the registry/emulation changes and finally found that setting the FEATURE_BROWSER_EMULATION Dword for my program to 2AF9 (which equates to "Mozilla/5.0 (Windows NT 6.2; Win64; x64; Trident/7.0; rv:11.0) like Gecko")did resolve the problem. No other value worked for me.

BTW found I only needed to make the change in hkey current user and amended my installer to make the changes for me: "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION"

Hope that helps someone.

Mar 17, 2016
#68 [email protected]
Adding this fixed my issue.  Thanks!

 <meta http-equiv="X-UA-Compatible" content="IE=edge">

Mar 18, 2016
#69 [email protected]
yes yes yes thanks a lot for

 <meta http-equiv="X-UA-Compatible" content="IE=edge">
Mar 24, 2016
#70 [email protected]
I have found this error as well, and sometimes dragging the street view icon onto the map will cause a similar script crash in util.js.

The meta tag has worked so far for me.
Apr 6, 2016
#71 [email protected]
Meta Tag worked for me as well; thanks!
Apr 8, 2016
#72 [email protected]
I have found this error as well, and sometimes dragging the street view icon into the map will cause a similar script crash in util.js. [2]
Apr 8, 2016
#73 [email protected]
Hallo, ich bin verzweifelt..

ich hab genau das gleiche Probleme.. kann mir jemand auf deutsch erklären, was zu tun ist?

Beste Grüße
May 25, 2016
#74 [email protected]
this has just started occurring today for me - no software changes
I get it in a Delphi TWebBrowser component.

What has changed? none of the above work unfortunately.
What is 'onion.js' trying to do?
May 25, 2016
Project Member #75 [email protected]
onion.js is trying to do a JSON.parse which IE7 doesn't have. Unfortunately webviews for IE default to IE7.
Please add the meta tag, which tell your webview to use Edge, which is a supported browser, and that should do the trick.
May 25, 2016
#76 [email protected]
Hi, 

I'm still having this issue even after I added the meta tag. I'm using WinDev on Windows 7 with no luck. I'm not sure IE7 could recognize IE = Edge since it didn't exist then.

May 25, 2016
#77 [email protected]
@roysharp.com I've got the same trouble today for v=3.22 and for v=3.23 too.
If I add
<meta http-equiv="X-UA-Compatible" content="IE=edge">
I see blank page in my browser.
How to fix this problem?
May 25, 2016
#78 [email protected]
I have de same problem lik denkalos. Some idea?
May 25, 2016
#79 [email protected]
Hi,

I and several of my customers are having the same problem with onion.js. The problem started first thing this morning (Wednesday 5/25) for both me and two of my customers and I suspect that Microsoft updated IE overnight. I have the "Install new versions automatically" checkbox checked. 

I tried adding the meta tag to my HTML file and it didn't help. I also tried setting FEATURE_BROWSER_EMULATION in HKLM and that didn't help either. 

The version of IE on my PC is 11.0.9600.18230, Update Versions: 11.0.29 (KB3139929).
May 25, 2016
Project Member #80 [email protected]
We did a version upgrade yesterday, and most notably we now have no more version that work IE7 (as there were security risks in the JS containing them). This all given IE7 is a 9+ year old browser.

Webviews (still today) default to IE7. It doesn't matter which IE you have installed.

Please write something like this in your file right from the beginning, before you construct a map.

var version = /MSIE ([0-9]+)/.exec(navigator.userAgent);
if (version && +version[1] <= 9) alert('You\'re using a deprecated IE version: ' + version[0]);


May 25, 2016
#81 [email protected]
The userAgent does return MSIE 7.0 but it's loading C:\Windows\SysWOW64\IEFrame.dll (confirmed by ProcMon) and the properties of that file show that the DLL version is 11.0.9600.18231.

I can probably get a more recent version response to navigator.userAgent if I load the DLL using the right GUID... or at least I can try that.

Thank you for your help.
May 25, 2016
Project Member #82 [email protected]
It doesn't matter which DLL you load. IE has build in compatibility mode. It is an IE11 that's is in IE7 mode, so it is an IE11 that has the JS of IE7. The same IE11 can be in IE10, IE9, IE8 IE7 (and I believe IE5) mode, but IE7 is the default for embedded browser components.

Loading a more recent DLL will only give you a more recent IE11 that's emulating IE7. You would need to convince IE11 not to do IE7, either via meta tags, or via registry keys.

Unfortunately this is where our supports stops, as you would understand, as this is an issue with IE not the JS that we ship.
May 26, 2016
#83 [email protected]
Since yesterday (5/25/2016) having same problem (JSON.parse undefined on onion.js) on IE11 Firefox and Chrome, after some pan&zoom on map.

After the error pan is blocked.

Some Idea?
chrome.png
95.6 KB   View   Download
firefox.png
70.0 KB   View   Download
May 26, 2016
#84 [email protected]
Hi,

Thanks for your explanation of MSIE7.0 emulation in IEFrame.dll. By any chance, does Google have OCX controls that host web windows inside of native desktop applications? :) I would be very happy to use alternatives and never have to use Microsoft technology again (and I was a 5-year Microsoftie in Windows Phone and WinCE).

jcc
May 27, 2016
#85 [email protected]
Re #83: Had the same problem not only in IE, it turns out that we were using an old version of mootools, that version was overriding de JSON object with his own. We couldn't change the version (legacy system) so we change the definition of the object to something more aware of the new JSON object, we took a look into newer version of mootools and created a version based on
May 27, 2016
Project Member #86 [email protected]
Probably Chromium Embedded Framework can be a good replacement for the IE WebBrowser control:

https://en.wikipedia.org/wiki/Chromium_Embedded_Framework
May 28, 2016
#88 [email protected]

I've bought a gps watch 3 years ago and the software for this watch worked very well. Now the famous "script error" appears if you put the mouse over any circular icon (e.g. airport icon). There is no difference using  windows 10 or vista & IE 9.

Thanks to #48! His link to  "https://weblog.west-wind.com/posts/2011/May/21/Web-Browser-Control-Specifying-the-IE-Version" helped me to fix the problem.

@#82: It's very unfortunately  to stop your support if you know that IE has default "IE7" in the embedded browser components. As a result your software changes break 3 years old software! 
May 30, 2016
#89 [email protected]
Same problem, we have some solution?
May 30, 2016
Project Member #90 [email protected]
The solution is to move away from IE7. Either via a register key, or a meta tag...

In case that is really beyond your control, I suppose you could drop in a JSON.parse polyfil, something like:
https://github.com/douglascrockford/JSON-js/blob/master/json_parse.js

But I wouldn't recommend it at all... IE7 is a close to 10 year old browser, and things are bound to be  breaking in them again.
May 30, 2016
#91 [email protected]
i fixed the problem testing from version 3.23;3.24;3.25 and it worked

*********** CONSTRUTOR ********************
public UsrCtrllocateCar()
        {
            InitializeComponent();

#if (DEBUG)
            SetIeModeDebug();
#elif (RELEASE)
            SetIeModeRelease();
#endif

......

}

********************************************


private void SetIeModeDebug()
        {
            var test = new System.Security.Principal.WindowsPrincipal(System.Security.Principal.WindowsIdentity.GetCurrent());
            if (test.IsInRole(System.Security.Principal.WindowsBuiltInRole.Administrator))
            {
                RegistryKey registryBrowser = Registry.LocalMachine.OpenSubKey
                (@"Software\\Microsoft\\Internet Explorer\\Main\\FeatureControl\\FEATURE_BROWSER_EMULATION", true);
                var currentValue = registrybrowser.GetValue("*");
                if (currentValue == null || (int)currentValue != 0x00002af9)
                    registrybrowser.SetValue("*", 0x00002af9, RegistryValueKind.DWord);
            }
            /*
            else
                this.Title += " - (must be started as administrator)";
             */
        }

        private void SetIeModeRelease()
        {
            var test = new System.Security.Principal.WindowsPrincipal(System.Security.Principal.WindowsIdentity.GetCurrent());
            if (test.IsInRole(System.Security.Principal.WindowsBuiltInRole.Administrator))
            {
                RegistryKey registrybrowser = Registry.LocalMachine.OpenSubKey
                    (@"Software\\Microsoft\\Internet Explorer\\Main\\FeatureControl\\FEATURE_BROWSER_EMULATION", true);
                string myProgramName = Path.GetFileName(System.Reflection.Assembly.GetExecutingAssembly().Location);
                var currentValue = registrybrowser.GetValue(myProgramName);
                if (currentValue == null || (int)currentValue != 0x00002af9)
                    registrybrowser.SetValue(myProgramName, 0x00002af9, RegistryValueKind.DWord);
            }
                /*
            else
                this.Title += " - (must be started as administrator)";
                 */
        }
May 30, 2016
Project Member #92 [email protected]
 Issue 9834  has been merged into this issue.
Jun 3, 2016
#93 [email protected]
Hi,

Back with more questions about the IEFrame.dll version and the script error at URL http://maps.googleapis.com/maps-api-v3/api/js/23/10/onion.js. By setting the FEATURE_BROWSER_EMULATION Registry entry to 0x2711, the returned userAgent string was changed to 

Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.1; WOW64; Trident/7.0)

The VIP on MSDN assures me that the version of JavaScript is controlled by FEATURE_BROWSER_EMULATION and the web extension is identifying itself as MSIE 10.0 so according to Microsoft, the JavaScript engine is IE 10.0 and Google removing support for MSIE 7.0 shouldn't be an issue anymore, right?. However, I'm still getting the error. Is there something else that I can do? Is there some other test other than userAgent to detect the JavaScript engine version?

Also, I have a question about what's going on when the script error occurs since the timing seems so random. Sometimes it happens almost immediately and other times it can run properly for several minutes while I'm actively dragging the map around, changing the zoom level, and adding and removing map tags. What is triggering the script error?

Thanks in advance for your help,
jcc
Jun 3, 2016
#94 [email protected]
Also, if I use src="http://maps.googleapis.com/maps/api/js?v=3.22", the script error occurs at http://maps.googleapis.com/maps-api-v3/api/js/23/10/onion.js,

If I use src="http://maps.googleapis.com/maps/api/js?v=3.24", the error occurs at http://maps.googleapis.com/maps-api-v3/api/js/24/11a/onion.js.

In both cases, it's Line: 0 Character: 0 Code: 0

Thanks,
jcc
Jun 6, 2016
#95 [email protected]
We started getting script errors in onion.js on 24 May, presumably when V3.24 went live.
We run IE 11 so it presumably isn't directly an IE issue.  We use the API through a C# host program. The code uses a Visual Studio webbrowser object which might be part of the problem.  We've tried all the suggestions above with no success.  The only thing that seems to be helping is to add an Registry entry for Software\\Microsoft\\Internet Explorer\\Main\\FeatureControl\\FEATURE_BROWSER_EMULATION. Putting in the key:
myapp.exe REG_DWORD 0x00002af9 (11001) seems to fix it for some machines.
It's clear to me that it's a V3.24 issue.  Is google investigating this?
Regards
Tony Reynolds
Jun 6, 2016
Project Member #96 [email protected]
 Issue 9875  has been merged into this issue.
Jun 6, 2016
Project Member #97 [email protected]
 Issue 9885  has been merged into this issue.
Jun 6, 2016
#98 [email protected]
We see the same issue with our application running:
http://maps.googleapis.com/maps-api-v3/api/js/23/10/onion.js

The Registry Emulation DWORD fix did not resolve on Windows 10.
Jun 6, 2016
Project Member #99 [email protected]
#95 and #98. Just because you have IE 11 installed, doesn't mean it's not IE7.

Microsoft has decided that all IEs should be capable of emulating previous versions. And that for embedded browser IE7 is the default. So you will get a IE11 that pretend to be IE7.

#80 has a code snippet to verify which IE version you are using.

Also #93,#94 and other could you please verify whether you have a JSON.parse

if (!window.JSON || !window.JSON.parse) alert('You are using a non-default/modern JS interpreter');

This should be a language native function.

Jun 6, 2016
#100 [email protected]
Re: #99 requesting info from #93/#94.

I ran your test and window.JSON is NULL. 

The userAgent string is: 
Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.1; WOW64; Trident/7.0)

The MSIE 10.0 browser passes the test but not the web extension claiming to be MSIE 10.0 compatible. I guess now it's back to Microsoft.

Thanks,
jcc
Jun 6, 2016
#102 [email protected]
Hi everyone, 

after suffered and surfed on google with this problem, that display error similar with #41, then found some good references and do trial and error.

Fisrt attemp, I tried to change the version from the obsolete (v3.15) to v3.24 (<script src='http://maps.googleapis.com/maps/api/js?key=" + gmapApiKey + "&sensor=true&v=3.24'> </script>), but still no luck. 

Second attemp, I tried to put <meta http-equiv='X-UA-Compatible' content='IE=edge'> on head section like others did, and rebuild the project. Viola, it works now. There's no error appear anymore.

IMHO, this is a compatibility issue like #58 said,  which is explain in here : https://blogs.msdn.microsoft.com/patricka/2015/01/12/controlling-webbrowser-control-compatibility/

I hope this one could be your reference to solve your problem.
Thank you
Jun 7, 2016
#103 [email protected]
The X-UA-Compatible mode may well work but it is deprecated by Microsoft.  Also, I can't use it with my app as it uses a modern feature.
I don't agree with #100 that it's a Microsoft problem - everything worked perfectly well before Google released their latest version. 
Jun 7, 2016
Project Member #104 [email protected]
#103
My sincere apologies for everybody who got broken by this change. But I think we live in a world where we have to accept that on the web we cannot support browsers for ever.
The breakage you see is because of a browser that is turning 10 (!) this year.

You can find our official browser support here:
https://developers.google.com/maps/documentation/javascript/browsersupport

You will see officially we don't support neither IE7, IE8 nor IE9, the first IE version that's officially supported is IE10. But we try not to break it... The fact that you only got broken now shows that we try to provide more care for old browsers than our official support line.

We would like to provide a world where we can support old browsers for every, but that basically means we can never make security improvements, or make use of performance improvements.

I think it's fair to see that there comes a point where browser support simply has to be ceased. And unfortunately IE7 is very, very, old. Microsoft doesn't support IE7 (nor IE8, and for most products IE9 and even IE10) anymore either. (http://www.infoworld.com/article/3020534/security/microsoft-will-end-support-for-internet-explorer8-9-and-10.html)
It's unfortunate that in this modern day and age, IE7 is the default provided by webviews, but alas that is outside of our control.

The alternative is supporting IE7 (and 6? or 5.5 (aka quirks mode?) ) for ever... 
Jun 7, 2016
#105 [email protected]
My opinion is that you are not addressing the issue. 
I think we would all accept that we don't expect Google to support browsers 10 years old.
But my firm and many commentators above are running the very latest version of IE - Version 11.
You informed us as #99 that "Just because you have IE 11 installed, doesn't mean it's not IE7" OK - so what do we do about it? 
At present there seems to be no way forward.  It seems clear that Google broke the API with  issue 3 .24.  Is this issue being looked into or not?
Regards
Tony Reynolds
Jun 7, 2016
Project Member #106 [email protected]
The way forward to is to put your IE11 in IE11 mode. As long as your IE11 keeps running as an IE7, it keeps being broken. Yes I do believe your 'firm' convinction you are using IE11. You are, but Microsoft has given its browsers the capability of running as an older version, bug to bug compatible. So alas, you are running IE11, but it's pretending to be IE7. IE11 has a JSON.parse, but your browser will delete that when its running as IE7, because IE7 didn't have it.

There are several ways, highlighted in this thread how you can address this problem and switch to IE11 mode.
First run the code snippet in #80 and #99. This will convince you, that indeed you are using IE7 and not IE11 (even tough IE11 is your installed version).
(If this IE11 running as IE10, IE9, IE8, or IE7 business confuses you, I would like to remind that that was not our decision, please contact your browser vendor about that)

- One way of getting into IE11 mode is presented in #48:
https://weblog.west-wind.com/posts/2011/May/21/Web-Browser-Control-Specifying-the-IE-Version
(this is not easy, so just verify JSON.parse actually exists)

- Another way of getting into IE11 mode is presented in #58
http://blogs.msdn.com/b/patricka/archive/2015/01/12/controlling-webbrowser-control-compatibility.aspx
Again some, please verify JSON.parse shows up when you've done that.

Here you can see JSON.parse support in browsers:
http://caniuse.com/#feat=json
You will see all modern browsers can do it, so we've starting to use a feature that was introduced in IE8.

- Another way of fixing is accepting IE7 (not what I would recommend, but it will work) and to install a JSON.parse polyfil. Like highlighted in #90. But if you ask me this is kicking the can down the road, because IE7 really is on its way out and more 'modern' features of several years old will be used.





Jun 8, 2016
#107 [email protected]
As others have recommended, I've got it to become stable using X-UA-Compatible mode.
It appears from what's been said that the root of the problems is that I've using a Microsoft webbrowser component in my app and that relies on IE7 code. I understand the recommendation above to "contact my browser vendor" but can I make a counter-suggestion that as it's commercially valuable to Google to have compatibility with MS products they should themselves make MS aware of this issue as their approach would have far more weight than an individual's.
Thanks to all that made suggestions.
Tony Reynolds
Jun 9, 2016
Project Member #108 [email protected]
 Issue 9904  has been merged into this issue.
Jun 16, 2016
Project Member #110 [email protected]
 Issue 9946  has been merged into this issue.
Jun 16, 2016
#111 [email protected]
Previously we are  using V3.2 Java script Google map API. Its working in IE8. 
Now We started getting script errors in util.js While run  in IE 8 from 24 May on words, We use the API through a java script program. we getting java script error while loading left panel is nothing but routes. 

we are using below api
 'http://maps.googleapis.com/maps/api/js'
Jun 16, 2016
Project Member #112 [email protected]
#111... 

Loading  http://maps.googleapis.com/maps/api/js without a paid account gives you experimental version currently 3.25. 
Could you confirm that  http://maps.googleapis.com/maps/api/js?v=3.24 or 3.23 also gives the error? 
That will help us analyze whether you're experiencing the same error.

Also could you tell us what error you actually get?

Since you  seem to be speaking of a 'left panel' and 'routes' can you confirm that you're not getting an error based on data drifts? (We updated some details/positions of a given point of interest?)
Jun 16, 2016
#113 [email protected]
We have a paid account and we are using the below api link in our application through java script to display the route map between two locations in IE8.
'https://maps.googleapis.com/maps/api/js?v=3.2&amp;key=XXXXXXXXXXXXXXXX'

Initially the route map screen displays the 'directions' in left side and the 'Map' in right side with out any issues(See Google_map.jpg).

But recently we observed that the same api link did not work properly and getting a java script error in IE8 (Observed on 05/24/2016).
Then we tried the same api with version 3.23 and 3.24 but got the same issue(google_map_v3.23_script_error.jpg and google_map_v3.24_script_error.jpg).

'http://maps.googleapis.com/maps/api/js?v=3.23&amp;key=XXXXXXXXXXXXXXXX' 
'http://maps.googleapis.com/maps/api/js?v=3.24&amp;key=XXXXXXXXXXXXXXXX'

Please verify the details and respond as early as possible.


Google_map.png
187 KB   View   Download
google_map_v3.23_script_error.JPG
99 KB   View   Download
google_map_v3.24_script_error.JPG
100 KB   View   Download
Jun 19, 2016
Project Member #114 [email protected]
#113
We're unaware of any IE8 breakages. I know it's not going to help a lot, but to start two things:

* version 3.2 doesn't actually exist. We're on 3.24 (release) 3.25 (experimental) now.
The idea is you request the experimental/release version. Then in the unlikely case a breakage happens, you can go to release/frozen and we have at least a quarter to sort things out. Unfortunately, if you request 3.2, you get frozen, so if that breaks you can't downgrade in the mean time as you've already downgraded yourself.

* IE8 unfortunately is also a browser that we don't actively support (neither is IE9). May I recommend not using IE8? Microsoft recommends not using it, and it's also a very old browser. This thread mainly deals with people using webviews who got IE7, if you're in a similar situation, can you make it use Edge, or a modern IE version?

Now the error message of IE8 is very unhelpful here: Error Code 0, at line 0, char 0.
Can you make a reproducible case in IE8 in a jsfiddle that shows this error? Or give us any other lead what is happening?
Jun 20, 2016
#115 [email protected]
we are using the paid account for google Map, Google Map driving direction getting the util.js error and also throw the onion.js exception while moving Map through the mouse..

if the system has the IE11 and Installed the registry key 11001(0X2AF9) for the respective EXE, then it's working fine


if the system has the IE10 and Installed the registry key 10001(0X2711), But it's not woking. The web browser throw the Util.js error

When we using the  <meta http-equiv="X-UA-Compatible" content="IE=edge">, Web browser display the blank, but show the driving direction Text and enclosed screen shot for this

Please find the following attachment


Map-Util-Error.PNG
164 KB   View   Download
Edge-Mode.png
36.7 KB   View   Download
Jun 20, 2016
Project Member #116 [email protected]
 Issue 9974  has been merged into this issue.
Jun 21, 2016
#117 [email protected]
Thanks for the info. We cannot use any latest versions like IE 10, 11 etc since our application supports up to IE 8 only and which is approved by our Client also. Please find attached the java script error with proper error details. Here is our code snippet for further review. Please verify and guide us with a proper solution to work it on IE 8 browser.

<script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?v=3.24&amp;key=XXXXXXXXXXXXXXXXXXXXXXX"></script>
        
<script type="text/javascript">
var directionsService;
var directionsDisplay;
function initialize() {
	var	source = '62 BOYD VALLEY RD SE,ROME,Georgia,30161';
	var	destination='14 B Nan-Lee Dr,Rome,Georgia,30165';
	
	var myOptions = {
		zoom: 10,
		mapTypeId: google.maps.MapTypeId.ROADMAP
	}
	var Map = new google.maps.Map(document.getElementById("map_canvas"), myOptions);
	
	if(directionsDisplay != null) {
		directionsDisplay.setMap(null);
		directionsDisplay = null;
	}
					
	directionsService = new google.maps.DirectionsService();
	directionsDisplay = new google.maps.DirectionsRenderer();
	
	directionsDisplay.setPanel(document.getElementById('directionsPanel'));
	directionsDisplay.setMap(null);
	directionsDisplay.setMap(Map);
	
	load(source, destination);
}

function load(source, destination){

	var request = {
			origin: source, 
			destination: destination,
			travelMode: google.maps.DirectionsTravelMode.DRIVING
		};
					
	directionsService.route(request, function(response, status) {
	  if (status == google.maps.DirectionsStatus.OK) {
		directionsDisplay.setDirections(response);
	  }
	});
}
Error.jpg
339 KB   View   Download
Jun 21, 2016
Project Member #118 [email protected]
Unfortunately IE8 is not a support browser anymore (Microsofts support actually ceased well before our support). We're happy to provide support (as in this thread) how people can not use unsupported IE versions, or how to avoid unknowingly using a deprecated IE version, which is what most of this thread is about.

But I'm afraid not supported actually means that well, we're not supporting people who 'chose' to use old IE version.

We try to communicate openly about our support, and have announced IE8 support deprecation a long time ago, we also document our browser's current support which is laid out here:
https://developers.google.com/maps/documentation/javascript/browsersupport

Our apologies if this policy leads to inconvenience and breakage :-( but unfortunately we just can't support browser for ever and we have to draw the line somewhere.
Jun 30, 2016
#119 [email protected]
We have windows application which loads google map in web browser control. When i update the latest version of API, the application throws "onion.js" error from the application.

We know Google supports only IE10 & IE11. Now our system has Windows 8 with IE10. We also tried updating the registry key for the application under "Feature_Browser_Emulation" and it is not working.


Please check and update us to resolve the issue.


Note: It worked well on starting of this week, and stopped working from today.
Google-Error.JPG
92.1 KB   View   Download
Jun 30, 2016
Project Member #120 [email protected]
 Issue 10040  has been merged into this issue.
Jun 30, 2016
Project Member #123 [email protected]
#119 just because you have IE 10 installed, doesn't mean you're using it, you might still very well being using IE7 (MS has made that the default for many scenarios)

#80 has a code snippet to verify which IE version you are using. Please run that and the snippet from #99 so you can verify whether you have a JSON.parse

if (!window.JSON || !window.JSON.parse) alert('You are using a non-default/modern JS interpreter');
Jul 1, 2016
#124 [email protected]
My problem was when debugging inside visual studio.  I also use the embedded ie browser on a form. It would most often display the onion.js script error after a few seconds or with some mouse movements.

I changed the key in local machine in the registry to as follows

Software\\Microsoft\\Internet Explorer\\Main\\FeatureControl\\FEATURE_BROWSER_EMULATION. Putting in the key:
myapp.vshosts.exe REG_DWORD 0x00002af8

Where myapp is the name of the executable.  This of course i garnered from the earlier writings of our colleagues

Now it works fine.  If I undo the change it fails, and when i return it it works fine.

Code snippet #80 from above works perfectly in detecting when it will fail.


Jul 4, 2016
Project Member #125 [email protected]
 Issue 10052  has been merged into this issue.
Jul 6, 2016
#126 [email protected]
I have also been having this problem with a .net application with an embedded IE browser. I haven't been able to get the metadata tag to work without just displaying a blank screen and I cannot update registry settings as the application is deployed using clickonce. 
One thing I have been able to do that seems to work so far is use a minified version of https://github.com/douglascrockford/JSON-js/blob/master/json2.js in my javascript to implement JSON.parse and JSON.stringify in the embedded browser. I'm sure that there will be more problems later as other modern functions are used, but so far this is the only thing that has worked for me.
Jul 7, 2016
#127 [email protected]
I had the js.onion error tonight. I switched the map from hybrid to satellite in the initialization file and the js.onion error went away when compiling.
Jul 7, 2016
#128 [email protected]
As my application should be always running in compatibility mode i.e IE 7, i cant use the meta tag for Edge so i downloaded Douglas Crockford's json2.js and now the error JSON undefined went away and its working perfectly fine.
Jul 7, 2016
#129 [email protected]
Thanks a lot CrockFord for the wonderful work with Json2.js
Jul 21, 2016
#130 [email protected]
Simply including Json2.js by CrockFord solved also the very same issue we had with json parse, which we had on Google chrome, even on its latest beta.

Google should send a prize to this guy...!
Aug 5, 2016
#131 [email protected]
Meta tag fix worked perfectly
Aug 19, 2016
#132 [email protected]
#58 

Quebrou meu galho! 
Aug 25, 2016
#133 [email protected]
 @ #60 [email protected]
Thank you for posting this!  This problem was in poly.js too,  and was killing my .net webbrowsercontrol.   I was able to "make it fail" then add the  <meta http-equiv="X-UA-Compatible" content="IE=edge"> clear cache then "make it WORK!"

I will be testing this on many computers tomorrow and I'll see if it fixes them.
Aug 31, 2016
Project Member #134 [email protected]
 Issue 10361  has been merged into this issue.
Sep 27, 2016
Project Member #135 [email protected]
 Issue 10534  has been merged into this issue.
Nov 22, 2016
#136 [email protected]
How to use json2.js in a vb6 project with webbrowser?
Nov 22, 2016
#137 [email protected]
Yes!!!!!! I got it!!!!!!!!

If someone else has this problem, try using

"<meta http-equiv=" + Chr(34) + "X-UA-Compatible" + Chr(34) + "content=" + Chr(34) + "IE=edge, scale=1.0, user-scalable=no" + Chr(34) + " />"
Nov 25, 2016
#138 [email protected]
I found another source of this problem, it is occurring when the map centre is being set arbitrarily e.g. center: {lat: 12.983333, lng: 77.583333}
However if i fetch the location from the API using the location address e.g. "Bengaluru, India' it works perfectly
Nov 26, 2016
Project Member #139 [email protected]
#138 Could you make a jsfiddle example of this problem? And describe in which browsers this occurs?
Jan 16, 2017
Project Member #140 [email protected]
 Issue 11269  has been merged into this issue.
Jan 16, 2017
Project Member #141 [email protected]
 Issue 11270  has been merged into this issue.
Jan 25, 2017
Project Member #142 [email protected]
 Issue 11330  has been merged into this issue.
Jan 25, 2017
#143 [email protected]
My problem occurs in delphi, witch utilizes GMLIB to execute the maps API inside it, the program works fine, with scrolling moving arround, etc. But as soon as 30~40 secs go by, the error occurs wenever i have the mouse over the map.

Attached is the error and the configurations that go in GMLIB, since that is what we use, there is no way to define the version it utilizes.
Onion Js.png
120 KB   View   Download
GMcfg.png
9.8 KB   View   Download
GMcfg2.png
10.2 KB   View   Download
GMcfg3.png
11.9 KB   View   Download
Jan 31, 2017
#144 [email protected]
merhaba friends,

you setup "GMMAP lib 1.5.3 version"
for problem 
"http://maps.googleapis.com/maps-api-v3/api/js/23/10/onion.js" 
Jan 31, 2017
#145 [email protected]
hello,
GM LİB 1.5.3 attact.
gmlib_v1-master.zip
3.2 MB   Download
Jan 31, 2017
Project Member #146 [email protected]
#143

Could you see whether the hints in #99 work for you? You're using an IE7 inside your delphi executable.

That post has some tips and hints for diagnosing your IE version and how you can use a more modern IE.
Feb 2, 2017
#147 [email protected]
I installed GM LIB 1.5.3 as suggested in #145,
as for #143 i checked it was using IE7 indeed, searched a little on how to set IE11 as the default browser for my aplication, and proceeded to alter the register as described in https://msdn.microsoft.com/library/ee330730.aspx. Didn't work, as a matter of fact, the time it takes to occur the error got even lower, now it takes 5 to 15 secs.

Thank you for all your atention!
Feb 2, 2017
#148 [email protected]
Created the register Value for GMapsTest.exe for 11001(decimal) and 0x2AF9 (hex) wich is supposed to force the application to run in IE11 regardless of the declared !DOCTYPE directive.
Feb 6, 2017
#149 [email protected]
I meant #146 in #147. "...as for #143 i checked..."
Feb 8, 2017
#150 [email protected]
I managed to solve the problem, somehow changing all emulation registry entries from IE7 with IE11 values, solved the situation. Thx for your help
Feb 8, 2017
#151 [email protected]
also added  different api key
Yesterday (19 hours ago)
Project Member #152 [email protected]
 Issue 11530  has been merged into this issue.
Sign in to add a comment

Powered by Google Project Hosting