bug 1094: Added new message regarding disputes on organisation domains
authorINOPIAE <inopiae@cacert.org>
Wed, 1 May 2013 10:34:07 +0000 (12:34 +0200)
committerINOPIAE <inopiae@cacert.org>
Wed, 1 May 2013 10:34:07 +0000 (12:34 +0200)
www/disputes.php

index 5b78c1e..b323457 100644 (file)
                        echo _("You aren't allowed to dispute your own email addresses. Can't continue.");
                        showfooter();
                        exit;
-               }       
+               }
 
                $res = mysql_query("select * from `users` where `id`='$oldmemid'");
                $user = mysql_fetch_assoc($res);
                $res = mysql_query($query);
                if(mysql_num_rows($res) <= 0)
                {
+                       $query = "select 1 from `orgdomains` where `domain`='$domain'";
+                       $res = mysql_query($query);
+                       if(mysql_num_rows($res) > 0)
+                       {
+                               showheader(_("Domain Dispute"));
+                               printf(_("The domain '%s' is included in an organisation account. Please send a mail to support@cacert.org to dispute this domain."), sanitizeHTML($domain));
+                               showfooter();
+                               exit;
+                       }
                        showheader(_("Domain Dispute"));
                        printf(_("The domain '%s' doesn't exist in the system. Can't continue."), sanitizeHTML($email));
                        showfooter();
                        echo _("You aren't allowed to dispute your own domains. Can't continue.");
                        showfooter();
                        exit;
-               }       
+               }
 
                $domainid = $row['id'];
                $_SESSION['_config']['domainid'] = $domainid;