Use objectManager to delete screenshots

This commit is contained in:
Alexander Nicolaysen Sørnes
2007-09-27 12:26:00 +02:00
committed by Chris Morgan
parent 715f3af1b3
commit 2823334eed
2 changed files with 5 additions and 2 deletions

View File

@@ -935,7 +935,8 @@ class ObjectManager
if($sAction)
$sUrl .= "&sAction=$sAction";
if($this->sReturnTo)
$sUrl .= "&sReturnTo=".urlencode($this->sReturnTo);
if(!$sTitle)
$sTitle = $this->sTitle;

View File

@@ -107,7 +107,9 @@ if($hResult && query_num_rows($hResult))
)
)
{
echo "<br />[<a href='screenshots.php?sCmd=delete&iImageId=$oRow->id&iAppId=".$aClean['iAppId']."&iVersionId=".$aClean['iVersionId']."'>Delete Image</a>]";
$oM = new objectManager("screenshot");
$oM->sReturnTo = "screenshots.php?iAppId=".$oScreenshot->iAppId."&iVersionId=".$oScreenshot->iVersionId;
echo '<br />[<a href="'.$oM->makeUrl("delete", $oScreenshot->iScreenshotId, "Delete Screenshot").'">Delete</a>]';
}
echo "</div></td>\n";