Web Images Videos Maps News Shopping Gmail more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Why can't Explorer compile the jsapi?
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  7 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Chris Schneider  
View profile  
 More options Nov 6, 7:28 pm
From: Chris Schneider <Sch...@TransPac.com>
Date: Fri, 6 Nov 2009 16:28:13 -0800 (PST)
Local: Fri, Nov 6 2009 7:28 pm
Subject: Why can't Explorer compile the jsapi?
Dear Google AJAX Gurus,

I'm trying to track down why Explorer can't display the Google Maps on
my site. IE7 (running on a PC I no longer have access to) reports the
same error as does my IE5.2 for the Mac OS. I worked up a minimal test
case to demonstrate the problem, which prevents any of the Google Maps
APIs from getting loaded (because google.load isn't successfully
loaded).

While loading the following test page:

http://www.vulgarianramblers.org/ie7_google_bug.php

Explorer will display the following alert (if 'Show scripting error
alerts' is enabled):

Microsoft JScript compilation error:
Line: 23
Char: 315
Error: Expected ')'

If you click the source button, it appears that the problem is due to
the JavaScript code loaded from http://www.google.com/jsapi?key=[my
key] via the <script></script> tags on line 9 of my own source. Once
the content from www.google.com is incorporated into my source, line
23 probably refers to the following line of google code:

(function() {var
d=true,f=null,g=false,h=encodeURIComponent,j=window,k=google,m=undefined,n= document;function
p(a,b){return a.load=b}var
q="push",s="replace",t="charAt",u="ServiceBase",v="name",w="getTime",x="len gth",y="prototype",z="setTimeout",A="loader",B="substring",C="join",D="toLo werCase";function
E(a){if(a in F)return F[a];return F[a]=navigator.userAgent[D]().indexOf
(a)!=-1}var F={};function G(a,b){var c=function(){};c.prototype=b
[y];a.R=b[y];a.prototype=new c}

Furthermore, it appears that the following JavaScript statement may be
the source of the compilation error:

if(a in F)return F[a];

I only have the JavaScript 1.1 reference (JavaScript - The Definitive
Guide, 2nd Ed.), in which only the "for ... in" construct is
described. I saw one reference online to the use of "in" alluded to
above, which appears to make use of the fact that associative array
keys are implemented as object properties (Unfortunately, I'm unable
to find that reference right now among the plethora of posts from
people who suggest using .indexof or looping to search arrays.)

If the above is truly legal JavaScript, then in what version was this
new "in" construct introduced? What browser versions (particularly of
Explorer) would support it?

Thanks,

- Chris


    Reply    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jeremy Geerdes  
View profile  
 More options Nov 6, 8:13 pm
From: Jeremy Geerdes <jrgeer...@gmail.com>
Date: Fri, 6 Nov 2009 19:13:31 -0600
Local: Fri, Nov 6 2009 8:13 pm
Subject: Re: Why can't Explorer compile the jsapi?
I am not seeing a syntax error in IE6 or IE7 for Windows. As far as  
IE5.2 for Mac is concerned, I don't know of anyone who still utilizes  
it for development or otherwise. The JSAPI is not intended to work  
with IE5.2 for Mac. For development, I would recommend Firefox with  
the Firebug plugin. These will get you farther in testing for IE6-8  
than IE5.2 for Mac, which was a dramatically different animal than any  
PC variant of IE. If you need further help, you could check out our  
IRC channel.

Jeremy R. Geerdes
Effective website design & development
Des Moines, IA

For more information or a project quote:
http://jgeerdes.home.mchsi.com
http://jgeerdes.blogspot.com
http://jgeerdes.wordpress.com
jgeer...@mchsi.com

Unless otherwise noted, any price quotes contained within this  
communication are given in US dollars.

If you're in the Des Moines, IA, area, check out Debra Heights  
Wesleyan Church!

And check out my blog, Adventures in Web Development, at http://jgeerdes.blogspot.com
  !

On Nov 6, 2009, at 6:28 PM, Chris Schneider wrote:


    Reply    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Chris Schneider  
View profile  
 More options Nov 7, 12:09 am
From: Chris Schneider <Sch...@TransPac.com>
Date: Fri, 6 Nov 2009 21:09:24 -0800 (PST)
Local: Sat, Nov 7 2009 12:09 am
Subject: Re: Why can't Explorer compile the jsapi?
Jeremy,

Thanks for responding and for trying out my test case on IE6 and IE7!
I called up my mother in law :) and had her confirm that this minimal
test case generates no errors on her machine either. (I swear that a
version of my real page was failing before on the jsapi code in the
same way as it was doing on IE5.2, but this is beside the point.)

I am certainly aware that IE5.2 for the Mac is a dead product, but
it's all I have available for testing here on my desktop. :( Just
getting that confirmation from my mother in law took about 30 minutes
of hand-holding. I hesitate to even ask for further help from the
community, but if someone out there was interested enough to just try
loading another page into IE7, please read on...

A test that is much closer to my goal still does fail on her machine
(of course). IE7 apparently now reports a syntax error on line 35,
column 5 of the following page:

http://www.vulgarianramblers.org/peak_detail_test.php?peak_name=Muir

The failing statement and the ones immediately before and after seem
fairly innocuous to me:

        var new_map = new google.maps.Map2(map_element);
        new_map.addMapType(google.maps.PHYSICAL_MAP);
        var topo_map_type = WMS_create_topo_map_type();

Note that this is a syntax error - the code above appears in a
function that doesn't get executed simply by loading the page.

I would appreciate any insight concerning why. (I'm also still
interested in that "in" construct I mentioned in my original post, but
I suppose I'll be able to answer that myself when my new JavaScript
book arrives next week.)

Thanks,

- Chris

On Nov 6, 5:13 pm, Jeremy Geerdes <jrgeer...@gmail.com> wrote:


    Reply    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Chris Schneider  
View profile  
 More options Nov 7, 12:33 am
From: Chris Schneider <Sch...@TransPac.com>
Date: Fri, 6 Nov 2009 21:33:18 -0800 (PST)
Local: Sat, Nov 7 2009 12:33 am
Subject: Re: Why can't Explorer compile the jsapi?
Gang,

P.S. - I guess I should have explicitly stated that everything is
already working well in Firefox and Safari. In particular, nothing
appears in the Firefox Error Console, and things look good poking
around in Firebug.

- Chris

On Nov 6, 9:09 pm, Chris Schneider <Sch...@TransPac.com> wrote:


    Reply    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Chris Schneider  
View profile  
 More options Nov 10, 3:59 pm
From: Chris Schneider <Sch...@TransPac.com>
Date: Tue, 10 Nov 2009 12:59:52 -0800 (PST)
Local: Tues, Nov 10 2009 3:59 pm
Subject: Re: Why can't Explorer compile the jsapi?
FYI,

I just got my new JavaScript guide (5th ed.), and there is a new use
of the "in" keyword to check property existence (see p.108 and Chapter
5). This use of what is now called the "in operator" is documented in
the book as being part of the JavaScript ECMA-262, version 3 standard
(available at http://www.ecma-international.org/publications/files/ecma-st/ECMA-262...),
but I was unable to find the in operator documented within that
standard. The book also claims that everything documented in the book
(i.e., including the in operator) should be supported by IE4, as well
as Netscape 4.5 and any more recent versions of other browsers.

- Chris

On Nov 6, 4:28 pm, Chris Schneider <Sch...@TransPac.com> wrote:


    Reply    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Chris Schneider  
View profile  
 More options Nov 10, 4:09 pm
From: Chris Schneider <Sch...@TransPac.com>
Date: Tue, 10 Nov 2009 13:09:26 -0800 (PST)
Local: Tues, Nov 10 2009 4:09 pm
Subject: Re: Why can't Explorer compile the jsapi?
FYI,

The *version 3* ECMA-262 is actually at the following URL:

http://www.mozilla.org/js/language/E262-3.pdf

I *does* contain the description of the "in operator" (see section
11.8.7).

- Chris

On Nov 10, 12:59 pm, Chris Schneider <Sch...@TransPac.com> wrote:


    Reply    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jeremy Geerdes  
View profile  
 More options Nov 10, 4:11 pm
From: Jeremy Geerdes <jrgeer...@gmail.com>
Date: Tue, 10 Nov 2009 15:11:09 -0600
Local: Tues, Nov 10 2009 4:11 pm
Subject: Re: Why can't Explorer compile the jsapi?
Thanks for the update, Chris.

Jeremy R. Geerdes
Effective website design & development
Des Moines, IA

For more information or a project quote:
http://jgeerdes.home.mchsi.com
http://jgeerdes.blogspot.com
http://jgeerdes.wordpress.com
jgeer...@mchsi.com

Unless otherwise noted, any price quotes contained within this  
communication are given in US dollars.

If you're in the Des Moines, IA, area, check out Debra Heights  
Wesleyan Church!

And check out my blog, Adventures in Web Development, at http://jgeerdes.blogspot.com
  !

On Nov 10, 2009, at 3:09 PM, Chris Schneider wrote:


    Reply    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google