While developing mods for ZC, I found myself struggling with the messy codes (I'm a bad programmer *___*). From time to time I had to go through tons of html codes to debug my mods, which is not good for my health .
I really miss the CakePHP and Rails *_*, I want separation of powers (oops, I mean logic and display codes). I want to let the designers change the "look" as they want, without having to know much about the logic behind it (and without touching my logic codes).
So I'm developing a mini framework to solve this, the goals are:
1. Taking advantage of Smarty template engine. Take most of the logic codes out of display codes(html).
2. Never ever edit any ZenCart files.
3. Allow users to take advantage of the framework only where they want, without having to make any change at any other place.
4. Stick to the way ZC works to avoid confusion: template files should be in templates folder, modules files(containing logic functions) should be in modules folder.
ZC's template over-ride system will still be effective.
5. Automatically calls the appropriate function and template based on the action.
6. Automatically validates all passed parameters before executing any functions.
7. Can be used in both "admin" and "includes".
This mod is currently under development, but it will be available in the near future. And once it's done I'll make sure all my current mods make use of it.
You can have a look at the latest revisions here:
https://svn.rubikintegration.com/zen...ate_framework/
If you have any suggestion, or if you want to help please let me know.
yellow1912
Bookmarks