This commit has been accessed 659 times via Git panel.
commit c2d57ce32951bbfccf8697489c592af6744a4a54
tree c15ef8547121b1abc2795d6607009826495c5aee
parent ac3dbc4644c2dc91cd5e6d0df909310068488b23
author Engels Antonio <engels@majcms.org> 1298978858 +0800
committer Engels Antonio <engels@majcms.org> 1298978858 +0800
Add check for disabled domains in From: aliases selection
diff --git a/post.php b/post.php
index 2a45326..e60e410 100644
--- a/post.php
+++ b/post.php
@@ -13,7 +13,7 @@ if (isset($_POST['new']) and !empty($_POST['new']) and is_numeric($_POST['new'])
$reply_from = "\"$usr_name\" <{$_SESSION['logged_uid']}>";
$reply_from = htmlentities($reply_from,ENT_QUOTES);
- $post_alias_query = mysql_query("select id from aliases where alias='{$_SESSION['logged_uid']}' order by domain, id");
+ $post_alias_query = mysql_query("select domains.id, aliases.id from aliases, domains where aliases.alias='{$_SESSION['logged_uid']}' and aliases.mode='1' and aliases.domain=domains.id and domains.mode='1' order by aliases.domain, aliases.id");
echo "<title>Kartero - Compose - {$_SESSION['logged_uid']}</title>";
diff --git a/send.php b/send.php
index e48ea54..84b602a 100644
--- a/send.php
+++ b/send.php
@@ -105,7 +105,7 @@ if (isset($_POST['msg']) and !empty($_POST['msg']) and is_numeric($_POST['msg'])
$header_tos = array_values(array_unique($header_tos));
- $send_alias_query = mysql_query("select id from aliases where alias='{$_SESSION['logged_uid']}' order by domain");
+ $send_alias_query = mysql_query("select domains.id, aliases.id from aliases, domains where aliases.alias='{$_SESSION['logged_uid']}' and aliases.mode='1' and aliases.domain=domains.id and domains.mode='1' order by aliases.domain, aliases.id");
echo "<title>Kartero - $folder - $reply_subject</title>";
tree c15ef8547121b1abc2795d6607009826495c5aee
parent ac3dbc4644c2dc91cd5e6d0df909310068488b23
author Engels Antonio <engels@majcms.org> 1298978858 +0800
committer Engels Antonio <engels@majcms.org> 1298978858 +0800
Add check for disabled domains in From: aliases selection
diff --git a/post.php b/post.php
index 2a45326..e60e410 100644
--- a/post.php
+++ b/post.php
@@ -13,7 +13,7 @@ if (isset($_POST['new']) and !empty($_POST['new']) and is_numeric($_POST['new'])
$reply_from = "\"$usr_name\" <{$_SESSION['logged_uid']}>";
$reply_from = htmlentities($reply_from,ENT_QUOTES);
- $post_alias_query = mysql_query("select id from aliases where alias='{$_SESSION['logged_uid']}' order by domain, id");
+ $post_alias_query = mysql_query("select domains.id, aliases.id from aliases, domains where aliases.alias='{$_SESSION['logged_uid']}' and aliases.mode='1' and aliases.domain=domains.id and domains.mode='1' order by aliases.domain, aliases.id");
echo "<title>Kartero - Compose - {$_SESSION['logged_uid']}</title>";
diff --git a/send.php b/send.php
index e48ea54..84b602a 100644
--- a/send.php
+++ b/send.php
@@ -105,7 +105,7 @@ if (isset($_POST['msg']) and !empty($_POST['msg']) and is_numeric($_POST['msg'])
$header_tos = array_values(array_unique($header_tos));
- $send_alias_query = mysql_query("select id from aliases where alias='{$_SESSION['logged_uid']}' order by domain");
+ $send_alias_query = mysql_query("select domains.id, aliases.id from aliases, domains where aliases.alias='{$_SESSION['logged_uid']}' and aliases.mode='1' and aliases.domain=domains.id and domains.mode='1' order by aliases.domain, aliases.id");
echo "<title>Kartero - $folder - $reply_subject</title>";