Hi all,
I'm having a problem with HTTPService
I have the file named "a.mxml" which contains a HTTPService
that calls to a url: "
http://localhost:8080/onlineshop.php".This php file will read the MySQL database and return a result in
XML format. As you know, the file "a.mxml" will read this XML
result and display it on the webpage. But the problem is when I
move the "bin-debug" folder to another place rather than its
original place and I run the a.swf file (the result of the file
a.mxml), it can't access the MySQL database and sent an error
message:
"[RPC Fault faultString="Security error accessing url"
faultCode="Channel.Security.Error" faultDetail="Destination:
DefaultHTTP"]
at mx.rpc::AbstractInvoker/
http://www.adobe.com/2006/flex/mx/internal::faultHandler()[E:\dev\3.1.0\frameworks\projects\rpc\src\... at
mx.rpc::Responder/fault()[E:\dev\3.1.0\frameworks\projects\rpc\src\mx\rpc\Responder.as:53]
at
mx.rpc::AsyncRequest/fault()[E:\dev\3.1.0\frameworks\projects\rpc\src\mx\rpc\AsyncRequest.as:103]
at
DirectHTTPMessageResponder/securityErrorHandler()[E:\dev\3.1.0\frameworks\projects\rpc\src\mx\messaging\channels\DirectHTTPChannel.as:368]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/redirectEvent()"
I've added a crossdomain.xml file right in the bin-debug
folder, and I wrote this in that file:
<?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="
http://127.0.0.1:8080/"secure="false"/> <!--i grant access to my local apache site
for the swf file-->
</cross-domain-policy>
but it still doesn't work
Do you guys have any ideas with this error?
Please help !
Thanks with regards
P/S: Please forgive for my bad English
🙂