johnny86 Posted February 4, 2011 Share Posted February 4, 2011 Hi, I've been thinking of different kind of solutions for allowing users to edit and provide CSS, JS and images through a CMS. The application is built on a framework which isn't a public open source project. But it follows the traditions of a basic framework and implements HMVC. In the application folder I have modules which are loaded upon request. The framework and application is outside the public_html directory. Now I need some kind of a decent solution to organize public resources. Because when an admin opens up a CMS and goes to administrate a specific module I need to provide the opportunity to edit CSS / JS / Images specific to that module. One solution I've been playing with is to create resources directory for every module and load everything from there to be edited in the CMS. Now that would be a straight forward easy solution. Except for the fact that I need to copy those files to the public_html and I somehow have to tell the application where from it will find those resources when the website is requested. I don't want to load all the CSS and JS from different files so I would like to create some kind of PHP script that will compile and cache the output and provide that for the client to reduce HTTP requests. For CSS / JS it would be one request each. That would also be very easy solution but for compiling the file I would need to load the whole framework and bootstrap the specific application to get hold of the paths that need to be compiled (not all modules are in use so I don't want to provide useless CSS / JS either) Does someone have toughts on this matter? Should I create some kind of a repository in the middle of CMS / Application which both will use to load but only CMS will update? What would be the best approach? Quote Link to comment https://forums.phpfreaks.com/topic/226701-application-cms-and-public-resources/ Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.