I'm working on the upgrade of one of my modules to work against CMSMS vs 1.10.
Up until now I have been using the SVN version of the core to get it up and running.
My Shop Made Simple module has the functionality to load images of products.
In the latest CMSMS versions trying to decrease needed internal memory has been introduced. I have been looking, as an example, to module News.
It has a lib/class.news_admin_ops.php that contains an handle_upload function. That is just what I'm looking for.
So I created library/class.shopmadesimple_admin_ops.php (I already used a library folder, so didn't want to create
another similar folder).
In the actual program that should perform the upload I've included:
Code: Select all
if( !class_exists('shopmadesimple_admin_ops') ) {
// This is required if we want to use the class
$fn = cms_join_path(dirname(__FILE__),'library','class.shopmadesimple_admin_ops.php');
require_once($fn);
}
$value = shopmadesimple_admin_ops::handle_upload($id,$error);
Can someone explain to me how to implement (which things go were) lazy loading?
Thanks in advance,
Duketown