admin管理员组

文章数量:1290102

My javascript won't load because of errors it receives, only in IE. I used debugger to get the following errors. This page renders the javascript correctly in Safari, FF and chrome but not in IE and only on specific pages like this.

.htm

1) No relay set (used as window.postMessage targetOrigin), cannot send cross-domain message

2) Invalid argument. jquery.min.js

Any ideas what the first error implies? I have switched out my jQuery build with the latest and it still does the same thing.

UPDATE I have updated my jquery.min.js to the latest and it I figured out this is where the page stops loading...after the invalid argument pops up in the jquery-latest.min.js, line 16 character 15511 which is the following letter 'b':

finally{b=[e,f],c=0}}return this}

My javascript won't load because of errors it receives, only in IE. I used debugger to get the following errors. This page renders the javascript correctly in Safari, FF and chrome but not in IE and only on specific pages like this.

http://tsqja.deznp.servertrust./Lakeside_721_2_Shelf_Heavy_Duty_Utility_Cart_p/lak-721.htm

1) No relay set (used as window.postMessage targetOrigin), cannot send cross-domain message

2) Invalid argument. jquery.min.js

Any ideas what the first error implies? I have switched out my jQuery build with the latest and it still does the same thing.

UPDATE I have updated my jquery.min.js to the latest and it I figured out this is where the page stops loading...after the invalid argument pops up in the jquery-latest.min.js, line 16 character 15511 which is the following letter 'b':

finally{b=[e,f],c=0}}return this}
Share Improve this question edited Aug 5, 2011 at 8:54 Luca Filosofi 31.2k9 gold badges71 silver badges77 bronze badges asked Jul 7, 2011 at 14:48 ToddNToddN 2,96115 gold badges60 silver badges101 bronze badges 3
  • 1 Looking through the source for that link I see you're using Google's +1 button. I'm currently trying to resolve a similar issue and Google Webmaster forums* doesn't appear to have a decent answer. Going to start a bounty for this. * google./support/forum/p/Webmasters/… – psema4 Commented Jul 29, 2011 at 20:21
  • 4 Debug from the minified jquery.min.js is almost meaningless. Try including the full jquery.js and sharing the debug from that. – cheeken Commented Jul 29, 2011 at 20:35
  • 1 IE7 does not support window.postMessage – epascarello Commented Aug 4, 2011 at 15:07
Add a ment  | 

1 Answer 1

Reset to default 10 +50

DEMO https://so.lucafilosofi./javascript-errors-no-relay-set-only-in-ie-7-8/

  • 1) - No relay set (used as window.postMessage targetOrigin), cannot send cross-domain message

is caused by the <g:plusone /> button on your site: ( google is busy of this notice ) the only way i found to circumnvent this issue is by doing something like this:

$(function() {
    setTimeout(function() {
        gapi.plusone.render("plusone-div");
    },
    1500);

});

  • 2) - Invalid argument. jquery.min.js

looking into your source-code is a chaos! ;-) OMG

  • you have lot's of errors like ( missing http:// protocol specified ):

  • different folder case-name like /v/newsite/ and /v/Newsite/ this really matter if you are under nix but since you are using ASP...

  • code like this AttachEvent(window, 'load', store_init); while using jquery like jQuery(document).ready(function() {

  • multiple inclusion of the same file ( this file is included 3 times ) /a/j/product_details.js

  • massive use of $(function(){ & $(document).ready(function(){ & $(window).load(function(){ multiple times when just one needed;

  • js global's all around the page, at the top, in the middle and at the bottom, they should stay all on top IMHO...

  • different version of jquery loaded at same time like: jquery-1.4.4.min.js & jquery-1.6.2.js & 1.4.2/jquery.min.js together

  • minor but always crappy, you have <meta /> , <link /> and <script /> in mixed order just like a chicken salad, where they should stay in order meta, links and script preferably at the end of the page.

  • missing semi-colon ; all around;

  • non-sense/malformed code like below and much much more...


if (!/\/shoppingcart\.asp/i.test(window.location.pathname)) {
    jQuery(document).ready(function() {
        jQuery('a').each(AddCartLink)
    });
}

var global_Config_EnableDisplayOptionProducts = 'False';

var global_ImageSeed = 'test.jpg';
global_ImageSeed = global_ImageSeed.substring(...

your site with no errors: https://so.lucafilosofi./javascript-errors-no-relay-set-only-in-ie-7-8/

what i have done is:

  1. reordered main tags meta,links,script
  2. removed shitty widgets like addthis, google, facebook
  3. "tried" to place all the globals to the top;
  4. mented the part of the code that cause chrome problems in the TopScriptsTEST5.js this file is your main problem, ( you should see an huge chunk of code mented )
  5. removed duplicate file inclusion,
  6. removed latest version of jquery, cause i strongly doubt that all the rest of your code work with the latest jquery version, so use the 1-4-4 instead
  7. some other fix here and there... nothing special

hope this check-up help a little, but i think you need an exorcist ;-)

本文标签: jqueryJavascript Errors quotNo relay setquotonly in IE 78Stack Overflow