Permission denied to call method in jQuery

Posted By  dotnetfish On 07 Sep 2010 10:09:43
emailbookmarkadd commentsprint
No of Views:4983
Bookmarked:0 times
Votes:0 times


I received below error message in firebug when i try to use jQuery Ajax call

var html = $.ajax({
url: "",
async: false}).responseText;

 Where is different domain from my current site.

Exception... "'Permission denied to call method' when calling method: [nsIDOMEventListener::handleEvent]" nsresult: "0x8057001e (NS_ERROR_XPC_JS_THREW_STRING)" location: "" data: no]

As far as my understanding, this is not allowed. In order to have the similar result, use Cross Domain getJSON or you can check on my sample in other post which work on cross domain ajax.

Ajax treat and as two different entry. There are different between url with www and without www. To solve this problem, use to get the url that use by visitors.


var html = $.ajax({
url: "http://" "/Realtime.ashx" + "?PostID=" + PostID,
async: false}).responseText; 

That's all, now problem in solved.Happy coding.

Sign Up to vote for this article
Other popular Tips/Tricks
By:DougDate Of Posted:6/3/2011 12:13:15 PM
Thank you
I'm not sure if I ever would have figured this out. without using i was getting repeated "Permission Denied" and "Object Expected" errors. This fix did away with them all.
By:E.Date Of Posted:12/17/2010 6:12:20 AM
wow this really helped me out! Thanks a lot.
Leave a Reply
Display Name:
(not display in page for the security purphase)
Please refresh your screen using Ctrl+F5
If you can't read this number refresh your screen
Please input the anti-spam code that you can read in the image.
^ Scroll to Top