I am not able to call the url for some reason. When i click on submit it says in the browser status bar 'Waiting for localhost...'. The swf file is located at
'http://localhost:8080/web/main.swf' so its on the same domain. Heres the code.
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
<mx:Panel x="121" y="87" width="422" height="234" layout="absolute">
<mx:Label text="User Name:"/>
<mx:Button label="Submit" click="userRequest.send()"/>
<mx:HTTPService id="userRequest" url="http://localhost:8080/app/login.do" useProxy="false" method="POST">
When i hit the url (http://localhost:8080/app/login.do) directly it works. But not via swf file. Any suggestions would be helpful. Thanks.
Is there another error message being thrown , can you debug the endpoint and see if it is being "Hit" by the swf request ? Throwing and actionscript resulthandler in there and debugging through flex builder should show you if the request is making it round trip.
You might also want to consider using something like Charles Proxy to see what is being transmitted and received. Another thing to consider is if you need a crossdomain.xml file in the locaiton of the service. (likely you do).
If you are using Flash Builder 4 Beta you can also use the Network Monitor which might give some insight.