javascript - Using CORS + SOAP + WCF for a HTTPS service -


i'm trying cors working new version of our soap web service (which runs under https , has username/password authentication) can connected via js.

at moment i'm getting working fine locally (not cross-domain) using different domain following wcf traceviewer. (400 bad request in iis7)

<exceptionstring>system.xml.xmlexception: body of message cannot read because empty.</exceptionstring> 

it seems it's not getting part message inspector runs add appropriate cors headers.

has experienced before or managed cors work under https soap service?

i'd appreciate advice can give.

cheers, jamie

actually can implement response custom header per request this.

response.appendheader("access-control-allow-origin", "*"); 

there more ways this. can chooise is. enabling cross domain access on wcf articles? implemented project used wcf service wcf , wcf service hosts on cross domain. can use jsonp webhttp binding. example answer here;

cross domain jquery ajax request & wcf rest service

or can implement configuration this:

<system.webserver>  <httpprotocol>   <customheaders>    <add name="access-control-allow-origin" value="*" />   </customheaders>  </httpprotocol> </system.webserver> 

for best way implement/enabling cors please check enable-cors.org site. can found easyly link.

http://enable-cors.org/server_wcf.html

at least can use jsonp instead of json. free difficult handle.

i wonder chooise it.


Comments

Popular posts from this blog

javascript - DIV "hiding" when changing dropdown value -

Does Firefox offer AppleScript support to get URL of windows? -

android - How to install packaged app on Firefox for mobile? -