admin管理员组

文章数量:1418103

My application's JavaScript is working on Firefox and IE but it is not working in Google Chrome. Is it problem of enable javascript in Google chrome? or I must put any code in javascript for getting XMLHttpRequest Object of Google chrome browser.

My application's JavaScript is working on Firefox and IE but it is not working in Google Chrome. Is it problem of enable javascript in Google chrome? or I must put any code in javascript for getting XMLHttpRequest Object of Google chrome browser.

Share Improve this question asked Apr 17, 2009 at 10:50 ashish bhattashish bhatt 3,1615 gold badges26 silver badges23 bronze badges 3
  • Can you give us an example of something that's not working? What about a simple alert() ? – Wayne Koorts Commented Apr 17, 2009 at 10:54
  • yes, I call one function of javascript when <input type="text" id="txt_acname1" runat="server" style="height:18px;Width:118px;" maxlength="30" onblur="ajaxFunction(this.value)" /> It will not give one alert which is given in that at the starting of this function. please help me. – ashish bhatt Commented Apr 17, 2009 at 11:14
  • I got two errors in that Like Sys is not define Sys.WebForms.PageRequestManager._initial... document.getElementById('aspnetForm')); and Sys.Application.initialize(); – ashish bhatt Commented Apr 17, 2009 at 11:31
Add a ment  | 

4 Answers 4

Reset to default 1

If the code works in two other browsers but not in Chrome, you need to look at the code for your "ajaxFunction" because that is apparently what is giving Chrome a headache. As @Artem mentioned, Ctrl+Shift+J will bring up the Javascript Console (switch it to the "Scripts" tab) and you can easily examine any errors.

Google Chrome's Javascript engine interprets JS very similarly to the other browsers mentioned. What is it that doesn't appear to be working?

There is a Javascript Console in Chrome, press Ctrl+Shift+J to open it and check for errors.

Is this question related to this problem? Problem could be that .NET thinks you're using the Safari Browser instead of Chrome...

本文标签: aspnetJavascript for Google Chrome detecting amp Enable javascript in Google ChromeStack Overflow