- implemented check for used APS packages on domain-deletion, fixes #110

This commit is contained in:
Michael Kaufmann (d00p)
2010-04-07 07:47:20 +00:00
parent f8d0472274
commit 16135fb92b
5 changed files with 65 additions and 0 deletions

View File

@@ -147,6 +147,14 @@ if($page == 'domains'
if(isset($_POST['send'])
&& $_POST['send'] == 'send')
{
/*
* check for APS packages used with this domain, #110
*/
if(domainHasApsInstances($id))
{
standard_error('domains_cantdeletedomainwithapsinstances');
}
$query = 'SELECT `id` FROM `' . TABLE_PANEL_DOMAINS . '` WHERE (`id`="' . (int)$id . '" OR `parentdomainid`="' . (int)$id . '") AND `isemaildomain`="1"';
$subResult = $db->query($query);
$idString = array();