Connecting Tech Pros Worldwide Forums | Help | Site Map

Microsoft.XMLHTTP permssion denied

Member
 
Join Date: Jan 2008
Posts: 53
#1: Jul 29 '09
hi,

below is a snippet of javascript code. this code works perfectly EXCEPT on one machine (maybe more that i don;t know about where the last line throws a permission denied. I've done comparisons across 2 machines with the same O/S and browser version. it works fine on 1 but not the other - any ideas ?

Expand|Select|Wrap|Line Numbers
  1. xmlHttpReq = new ActiveXObject("Microsoft.XMLHTTP"); 
  2. var strURL = "http://www.xxx.com/emailsend.asp"
  3. var params = "strAgencyToEmail=" + pID + "&Source=Admin"
  4. xmlHttpReq.open('POST',strURL,true);
etc...

Canabeez's Avatar
Member
 
Join Date: Jul 2009
Location: Israel
Posts: 85
#2: Jul 29 '09

re: Microsoft.XMLHTTP permssion denied


Crossdomain requests are NOT allowed in XMLHttpRequest(), I suggest you use JSON.
Member
 
Join Date: Jan 2008
Posts: 53
#3: Jul 29 '09

re: Microsoft.XMLHTTP permssion denied


why do you say it's a cross domain request ? Is my syntax wrong. As i say it works on seemingly 99% of pc's
Canabeez's Avatar
Member
 
Join Date: Jul 2009
Location: Israel
Posts: 85
#4: Jul 29 '09

re: Microsoft.XMLHTTP permssion denied


Quote:

Originally Posted by TimSki View Post

Expand|Select|Wrap|Line Numbers
  1. var strURL = "http://www.xxx.com/emailsend.asp"

Is this the PC domain, if not - it's crossdomain. Usually getting something at the same domain, you just "/emailsend.asp", no need for a domain.
Reply


Similar JavaScript / Ajax / DHTML bytes