I'm using Zend framework, and most of the action controller that I have return XML response. In order to do this, I have to initialize context switching and provide URL suffix "?format=xml" to call each action.
Is there any way to make this default? So I don't have to add this suffix each URL?
Regards, Andree.
EXTRA EXTRA.. READ ALL ABOUT IT!
http://framework.zend.com/manual/en/zend.controller.actionhelpers.html
Have a look at ContextSwitch and AjaxContext
(Edit) Suggest you use:
In some cases, you may want to force the context used; for instance, you may only want to allow the XML context if context switching is activated. You can do so by passing the context to initContext():
$contextSwitch->initContext('xml');
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With