Never been to DZone Snippets before?

Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

« Newer Snippets
Older Snippets »
Showing 1-1 of 1 total  RSS 

Flash 8 AS2 REMOTING with AMFPHP

This code should be used to perform remoting with Flash 8 using ActionScript 2.

// remoting
import mx.remoting.Service;
import mx.remoting.PendingCall;
import mx.rpc.RelayResponder;
import mx.remoting.debug.NetDebug;

NetDebug.initialize();

var myResponder:RelayResponder = new RelayResponder(this,"say_Result","say_Fault");
var siteCFC:Service = new Service("http://127.0.0.1/flashservices/gateway.php",null,"HelloWorld",null,myResponder);
var temp_pc:PendingCall = siteCFC.say("Hola chicos!");

function say_Result(re){
	trace(re.result);
}
function say_Fault(result){
	trace("error!");
}
« Newer Snippets
Older Snippets »
Showing 1-1 of 1 total  RSS