fixing the image asset

This commit is contained in:
JT Smith 2004-12-25 18:13:38 +00:00
parent 27356b09f6
commit 856ee6fd18
5 changed files with 66 additions and 35 deletions

View file

@ -70,11 +70,14 @@ sub page {
$method = $session{form}{func};
}
$method = "www_".$method;
$output = $asset->$method();
if ($output eq "" && $method ne "view") {
$output = $asset->www_view;
$output = eval{$asset->$method()};
if ($@) {
WebGUI::ErrorHandler::fatalError("Couldn't call method ".$method." on asset for ".$asset->get("url")." (".$asset->getId."). Root cause: ".$@);
} else {
if ($output eq "" && $method ne "view") {
$output = $asset->www_view;
}
}
WebGUI::ErrorHandler::fatalError("Couldn't call method ".$method." on asset for ".$asset->get("url")." (".$asset->getId."). Root cause: ".$!) if ($!);
}
WebGUI::Affiliate::grabReferral(); # process affilliate tracking request
if (WebGUI::HTTP::isRedirect() && !$useExistingSession) {