This page is no longer updated - please visit http://ghostwire.com Thank you!
 

« PHPObject »
An Opensource Alternative to Flash Remoting
Current Release
Readme
Notes
Journal
Archives

Notes
Sunday April 20, 2003

Using getOutput() method

The getOutput() method of PHPObject class was added in v1.3 to allow the retrieval of output from php classes. If the remote method you call has an output (echo, print, etc.), the output will be sent back to flash along with the object's properties. This output can be retrieved in flash with getOutput().

PHP class
class Foo
{
    function Foo() {
    }

    function sayIt($name) {
        echo "My name is $name\n";
        echo "Who are you?\n";
    }
}

Flash
myFoo = new PHPObject("Foo");
myFoo.sayIt_onResult = function() {
    trace(this.getOutput());
}
myFoo.sayIt("John");

Posted by sunny at April 20, 2003 12:14 PM

 

Comments

 

Post a comment









Remember personal info?







Zones



Forums