I'm not sure I understand the role of jQuery/JavaScript in MVC. I've found an article about it on A List Apart, but it doesn't clear anything up for me.Does it bridge the communication between the View and the Controller, or does it do something else?
What is jQuery and JavaScript's role in MVC?
mvc;jquery
Javascript is not related to the zend framework, or anything you use on the server. It runs in the browser. (Yes it could run anywhere but let's simplify)Let's say you have a desktop application that is programmed using the MVC pattern and at some point it needs to make a request to a server to fetch some data. To fulfill the request, the server might be using MVC pattern or it might not, it doesn't relate in any way to the desktop application.Javascript works the same way but traditionally is more dependent on making requests to a web server than a desktop application. But it doesn't have to be, with html5 offline capabilities, file reading and localstorage you can make a desktop style javascript app that doesn't use any server at all but still runs in the browser. Now, you could design the javascript app using MVC or whatever you see fit but it doesn't relate to what any server you might be making requests to is using.So to answer your question, there is no role for javascript in zend MVC. The zend MVC controller is only invoked by HTTP requests, while if you were to use MVC in javascript, the controller in javascript MVC would be invoked by various user actions in the app. And jQuery is just a bunch of javascript, so it applies for jQuery as well.