class user_classes {
var $cObj;
// The backReference to the mother cObj object set at call time
/**
* Call it from a USER cObject with 'userFunc = user_randomImage->main_randomImage'
*/
function filesizeFunc($content, $conf) {
$file = $this -> cObj -> TEXT($conf['file.']);
if(file_exists($file)) {
$fileSize = filesize($file);
if($fileSize) {
$fileSize = t3lib_div::formatSize($fileSize, ' Byte| kB| MB| GB');
$fileSize = $conf['wrap'] ? $this -> cObj -> wrap($fileSize, $conf['wrap']) : $fileSize;
}
}
//$filetype = "PDF";
$tempfiletype = t3lib_div::split_fileref ($file);
$filetype = $tempfiletype['realFileext'];
$filetype = t3lib_div::strtoupper($filetype);
$fileSize = "
(".$filetype.", ".$fileSize.")";
return $fileSize;
}
function addHashtag($content,$conf) {
$hashTag = $this->cObj->stdWrap($conf['hastag'], $conf['hastag.']);
$content['TAG'] = '';
return $content['TAG'];
}
}
?>