10 Replies Latest reply on Sep 12, 2010 12:47 PM by mumcs01

    Httpservice to localhost doesn't work in Flex4... Even with crossdomain.xml

    mumcs01 Level 1

      So, this was working before I recompiled with Flex4, (In Flex 3.5) and now I can't get the following to work....

       

      Story:

      I'm using httpservice in flex like:

      <mx:HTTPService id="getConfig" url="http://localhost/parser.php" method="POST" showBusyCursor="true" resultFormat="e4x" result="xmlresultHandler(event)" fault="faultHandler(event)" />

       

      Everything is in my root directory on my web server. When run in debug or directly from flashbuilder, the call works fine. If I run a release build, and FTP the release to /var/www (my root), and try to browse to the server, the website pulls up, and the swf file runs, but I always get a

      Fault:Channel.Security.Error

      FaultString:'Security error accessing url'

      faultDetail:'Destination:DefaultHTTP'

       

      when it trys to read the httpservice.

       

      I do have a crossdomain.xml file in my /var/www (webroot) folder with what I see as super permissive settings.... Below:

       

      <?xml version="1.0"?>
      <!DOCTYPE cross-domain-policy SYSTEM "http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd">
      <cross-domain-policy>
      <allow-access-from domain="*" to-ports="*" />
      <site-control permitted-cross-domain-policies="all" />
      <allow-http-request-headers-from domain="*" headers="*" />
      </cross-domain-policy>

      Any help would be GREATLY appreciated.