5095 Posts in 1518 Topics by 1114 members
|Go to End|
4 January 2012 at 5:38pm Last edited: 4 January 2012 5:38pm
Is it possible to override or extend the Requirements and Requirements_Backend classes?
I want to add CDN URL support for loading CSS/JS resources so that I can get the combined CSS/JS files to be pulled from an external CDN URL.
I got this working by modifying the Requirements/Requirements_Backend classes but am looking for a more cleaner solution that does not involve hacking the core files.
Any hints/help on this?
Jatinder Singh Thind
4 January 2012 at 7:26pm
You can subclass Requirements_Backend then, in your _config.php or Page_Controller::init(), call Requirements::set_backend(new MyBackend);
4 January 2012 at 11:23pm
That worked perfectly. Thanks a lot Simon.
|Go to Top|