17/09/2012 10:07am

PHP | Problem -


<?php

class ExtraImageFunctions extends DataExtension {
function generateThumb_60_60($gd) {
$my_image = $gd->setQuality(90);
$my_image = $gd->croppedResize(60,60);
return $my_image;
}

function generateFull_800_600($gd) {
$my_image = $gd->setQuality(90);
$my_image = $gd->resizeRatio(800, 600);
return $my_image;
}

function generatePageImage($gd) {
$my_image = $gd->setQuality(90);
$my_image = $gd->croppedResize(300, 255);
return $my_image;
}
}

<?php

global $project;
$project = 'mysite';
/*.... */
DataObject::add_extension('Image', 'ExtraImageFunctions');


Post Comment