سؤال

I have been working on an adobe air app using PHP as my server side language.

I am transferring data in AMF using amfphp and things were going well.

I recently decided to make use of the codeigniter framework, integrating amfphp + codeigniter was taking longer than necessary so I downloaded Zend_AMF

After going through some tutorials, i was able to set up zend_amf + codeigniter.

I however get the following error in flex

"faultCode:Client.Error.MessageSend faultString:'Send failed'        
 faultDetail:'Channel.Connect.Failed error NetConnection.Call.BadVersion: : 
 url: 'http://127.0.0.1/project/index.php/amf/gateway/gateway/''

so i decided to use an http proxy application to monitor my calls and what is being returned. Charles seemed the perfect choice as it parses AMF data properly. unfortunately though, remote calls from my air app do not show up in charles.

I learnt that there is no way to change proxy settings for an air application as it makes use of the default system proxy setting, i updated my internet explorer proxy setting as i learnt it has a system wide effect. After changing this setting, it still doesnt work.

I however downloaded fiddler(http://fiddler2.com). Although it doesnt parse AMF data properly, it logs my http request.

Any pointers as to why charles isnt logging the requests will be most appreciated

هل كانت مفيدة؟

المحلول

This is a general issue when you want to check traffic on localhost. There is a workaround described in the Charles Proxy FAQ:

Some systems are hard coded to not use proxies for localhost traffic. Specifically IE 7 and .Net applications have this feature.

The workaround is to connect to http://localhost./test/ instead (note the . after localhost). This should work identically to localhost normally but with the advantage that it will go through Charles.

Alternatively you can replace localhost with the name of your machine, or your local link IP address (eg. 192.168.1.2). So rather than connecting to http://localhost/test/ you connect to http://machinename/test/

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top