[TYPO3-english] Using image function in user functions
Tapio Markula
tapio.markula at xetpoint.fi
Wed Nov 26 12:23:22 CET 2008
Hi
I would like to use image manipulation in user function.
I got information that I should use something like $this->cObj->IMAGE()
lets presume this in TS Template
includeLibs.hsme_string = fileadmin/ext-templates/user_myreplace.inc
tt_content.text.20 {
parseFunc {
userFunc=user_myreplace->user_myreplace
}
}
}
In order to use $this->cObj->IMAGE() should I first include the basic
class and then make instance like this?
<?php
require_once ( PATH_site .
'typo3/sysext/cms/tslib/class.tslib_content.php' );
class user_myreplace {
var $cObj;
function user_myreplace ($content="",$conf=array()) {
$this->cObj = t3lib_div::makeInstance('tslib_cObj');
$image=$this->cObj->IMAGE($conf);
...
return $this->content;
}
}
?>
should I have
require_once(PATH_tslib."class.tslib_pibase.php");
More information about the TYPO3-english
mailing list