From 05e71c79c93801ab6a8262fbd93d1af3d5bdace4 Mon Sep 17 00:00:00 2001 From: pedro_morgan <pedro_morgan@ispconfig3> Date: Sun, 19 Aug 2007 00:31:55 -0400 Subject: [PATCH] * Made login/index class php5 * Also replaces " with ' --- interface/web/sites/web_domain_edit.php | 18 ++++++++++++++++++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/interface/web/sites/web_domain_edit.php b/interface/web/sites/web_domain_edit.php index f925bd2..cb3d57e 100644 --- a/interface/web/sites/web_domain_edit.php +++ b/interface/web/sites/web_domain_edit.php @@ -250,6 +250,24 @@ } + function onAfterDelete() { + global $app, $conf; + + // Delete the sub and alias domains + $child_domains = $app->db->queryAllRecords("SELECT * FROM web_domain WHERE parent_domain_id = ".$this->id); + foreach($child_domains as $d) { + // Saving record to datalog when db_history enabled + if($app->tform->formDef["db_history"] == 'yes') { + $app->tform->datalogSave('DELETE',$d["domain_id"],$d,array()); + } + + $app->db->query("DELETE FROM web_domain WHERE domain_id = ".$d["domain_id"]." LIMIT 0,1"); + } + unset($child_domains); + unset($d); + + } + } $page = new page_action; -- Gitblit v1.9.1