diff --git a/interface/web/dns/dns_alias_edit.php b/interface/web/dns/dns_alias_edit.php
index 20bbc38d8646db029cc0ab6993ee89340eac85a8..3dfb59dead91b58f8fe3c12bd1f192144ff3cdbf 100644
--- a/interface/web/dns/dns_alias_edit.php
+++ b/interface/web/dns/dns_alias_edit.php
@@ -51,6 +51,17 @@ class page_action extends dns_page_action {
 		if($tmp['number'] > 0) return true;
 		return false;
 	}
+
+  function onSubmit() {
+		global $app, $conf;
+		// Get the parent soa record of the domain
+		$soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = ? AND " . $app->tform->getAuthSQL('r'), $_POST["zone"]);
+		// Replace @ to example.com. in data field
+		if($this->dataRecord["data"] === '@') {
+			$this->dataRecord["data"] = $soa['origin'];
+		}
+		parent::onSubmit();
+	}
 }
 
 $page = new page_action;
diff --git a/interface/web/dns/dns_cname_edit.php b/interface/web/dns/dns_cname_edit.php
index 38bb8140c47f06b5b144a57b980ead18768c63ed..e2fde267d22a0008b5e30787a5af95292e11f1f6 100644
--- a/interface/web/dns/dns_cname_edit.php
+++ b/interface/web/dns/dns_cname_edit.php
@@ -53,6 +53,16 @@ class page_action extends dns_page_action {
 		return false;
 	}
 
+	function onSubmit() {
+		global $app, $conf;
+		// Get the parent soa record of the domain
+		$soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = ? AND " . $app->tform->getAuthSQL('r'), $_POST["zone"]);
+		// Replace @ to example.com. in data field
+		if($this->dataRecord["data"] === '@') {
+			$this->dataRecord["data"] = $soa['origin'];
+		}
+		parent::onSubmit();
+	}
 }
 
 $page = new page_action;
diff --git a/interface/web/dns/dns_dname_edit.php b/interface/web/dns/dns_dname_edit.php
index a1e1cb6c073cc9313e2c6d1b9952c5221a5ba486..4e97a8632c541bf3d48a9878297ff3b08be8dd2b 100644
--- a/interface/web/dns/dns_dname_edit.php
+++ b/interface/web/dns/dns_dname_edit.php
@@ -52,6 +52,17 @@ class page_action extends dns_page_action {
 		if($tmp['number'] > 0) return true;
 		return false;
 	}
+
+	function onSubmit() {
+		global $app, $conf;
+		// Get the parent soa record of the domain
+		$soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = ? AND " . $app->tform->getAuthSQL('r'), $_POST["zone"]);
+		// Replace @ to example.com. in data field
+		if($this->dataRecord["data"] === '@') {
+			$this->dataRecord["data"] = $soa['origin'];
+		}
+		parent::onSubmit();
+	}
 }
 
 $page = new page_action;
diff --git a/interface/web/dns/dns_edit_base.php b/interface/web/dns/dns_edit_base.php
index a94bd54946d3cc0fe67d28d6361863ad6a21908a..61c08f6576a9f6eff032b249728d2a0e2210d56e 100644
--- a/interface/web/dns/dns_edit_base.php
+++ b/interface/web/dns/dns_edit_base.php
@@ -104,7 +104,7 @@ class dns_page_action extends tform_actions {
 			$client_group_id = intval($_SESSION["s"]["user"]["default_group"]);
 			$client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = ?", $client_group_id);
 
-			// Check if the user may add another mailbox.
+			// Check if the user may add another record.
 			if($this->id == 0 && $client["limit_dns_record"] >= 0) {
 				$tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = ?", $client_group_id);
 				if($tmp["number"] >= $client["limit_dns_record"]) {