This is a question about the architecture.
I've seen two approaches implementing AJAX layer in Zend Framework.
The first one, traditional, using AjaxContext action helper (index.phtml
and index.ajax.phtml
). This has always a nice fallback when no JavaScript is available.
The second one, implementing separate controllers for AJAX (disable the layout by default etc.)
I wonder about the possible advantages and drawbacks of those two solutions in the long run.
Which one would you recommend and why?
(I'm using ZendX jQuery)