2009年5月11日星期一

Re: [fw-mvc] Using Zend_Amf and Flex in Zend framework

How about you just use Zend_Application and bootstrap the resources that you need for your app (the database, etc.), call Zend_Application in regular php file, and in that file instantiate your Zend_Amf_Server. I imagine your presentation is going to be done in flex anyway. Why bother with the whole MVC stack just to get some data in to flash?

On Mon, May 11, 2009 at 9:52 PM, ShiVik <vikramvmalhotra1983@gmail.com> wrote:

hello all,

I am trying to make a small website using Flex and Zend framework. I am
trying to use Zend_Amf for receiving the requests from flex. I have only
started with the Zend_Amf. I am having a trouble in figuring out where to
put the Zend_Amf in Zend framework.

I thought of placing Zend_Amf in the bootstrap file or inside the
controller. The second option doesn't seem right as I will have to place the
Zend_Amf in every one of my controllers' action. That doesn't seem right.
But in bootstrap file, I can put only one class map. I might need many
classes.

 $server = new Zend_Amf_Server();
 $server->setClass('Contact');
 $server->setClassMap('ContactVO', 'Contacts');
 $response = $server->handle();
 echo $response;

Can anybody guide me with this?

Thanks and Regards
ShiVik
--
View this message in context: http://www.nabble.com/Using-Zend_Amf-and-Flex-in-Zend-framework-tp23494835p23494835.html
Sent from the Zend MVC mailing list archive at Nabble.com.


没有评论: