ZF 2 - When to use Modules
Posted: Thu Oct 11, 2012 7:05 am
I just today started taking a seriously look at ZF 2. I would like to re-write this one small and fairly simple website in ZF 2 but it seams that the documentation and examples just aren't really there yet.
So, my first question deals with Modules. In ZF 1.* I made each section of the website a different module. There is the default (user side) and the admin modules. Each module had all the controllers, view, layouts, etc that was needed for that specific section. The only real thing in common between the modules was the database and main configuration, which is fine for me.
Now, ZF 2 seams to go in a different direction that I am not sure of yet. As far as I have been able to gather, 1 module in ZF 2 is just 1 page (controller) with all files needed for it. This doesn't seam so great for me though as my "companies" page is 100% different on the client side and admin side.
So, really, how should I be using Modules in ZF 2 and how should I separate the different sections (user, admin) within the code structure?
P.S. If anyone has any good tutorials on how to migrate from ZF 1 to 2 I would be very interested in those links.
So, my first question deals with Modules. In ZF 1.* I made each section of the website a different module. There is the default (user side) and the admin modules. Each module had all the controllers, view, layouts, etc that was needed for that specific section. The only real thing in common between the modules was the database and main configuration, which is fine for me.
Now, ZF 2 seams to go in a different direction that I am not sure of yet. As far as I have been able to gather, 1 module in ZF 2 is just 1 page (controller) with all files needed for it. This doesn't seam so great for me though as my "companies" page is 100% different on the client side and admin side.
So, really, how should I be using Modules in ZF 2 and how should I separate the different sections (user, admin) within the code structure?
P.S. If anyone has any good tutorials on how to migrate from ZF 1 to 2 I would be very interested in those links.