Im new to ActionScript and Flex 3... im trying to develop an MVC 100% OOP application with Flex 3 using MXML,AS3 and PHP.
M (PHP) V (MXML) C (AS3)
The 3 layers i choose for my development. I have 10 AS3 classes that are object related between them and some inherit or implement interfaces.
The only problem here is how to interact 100% OOP with my model. In this case my model has to be a PHP Class that needs to be called from AS3 (the controller).
For example the AS3 class : Patient have a method called Save:
public function Save(data:Array) : void
{
/* PHP call - model layer */
}
I want to create an instance of my PHP Patient Model class that connects to the DB and insert the data array into it.
What should i use ? how can i also return a variable to AS3 ? What happen to as3 if there is a cached Exception in PHP ?
Thanks in advanced :)