Cross Domain Webservices

Discussion in 'ASP.NET WebServices' started by mdobbles, Sep 9, 2008.

  1. I have a webservice that is accessed by a silverlight web application. It works fine when deployed to my discountasp.net site. The problem is that I would like to be able to debug my silverlight application when server off of localhost and still use the production web service which is staged at my discountasp.net site. That means a cross domain access of the webservice. I added the following crossdomain.xml file to the root of my site, but that didn't seem to help.

     
  2. Very cool of you to post the resolution. [​IMG]
     
  3. I solved it. The other thing I needed was a clientaccesspolicy.xml file.

     
  4. Okay, I got everything figured out and I incorporated it all into a step-by-step tutorial on how to build a datacentric silverlight web app that uses WCF andLINQ to submit and retreive data from a database. The deployment part was thehardest part, so the tutorial goes into some depth withthat. You can check it out at my blog at http://www.silverlightwebapps.com/Tutorials.aspx.
     
  5. mjp

    mjp

    Cool, thanks!
     
  6. Thanks for your tutorial!, you saved me.
     
  7. Are the 2 files really supposed to be identical?

    When I go to

    http://msdn.microsoft.com/en-us/library/cc197955(VS.95).aspx

    They list the crossdomain.xml as having the following format

    <?xml version="1.0"?>
    <!DOCTYPE cross-domain-policy SYSTEM "http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd">
    <cross-domain-policy>
    <allow-http-request-headers-from domain="*" headers="*"/>
    </cross-domain-policy>
     

Share This Page