bug 372: `orgdomlink` has no `id` field bug-372
authorMichael Tänzer <neo@nhng.de>
Tue, 29 Apr 2014 21:34:21 +0000 (23:34 +0200)
committerMichael Tänzer <neo@nhng.de>
Tue, 29 Apr 2014 21:34:21 +0000 (23:34 +0200)
Signed-off-by: Michael Tänzer <neo@nhng.de>
includes/account.php

index 7e9ee2a..25e2608 100644 (file)
@@ -2079,7 +2079,7 @@ function buildSubjectFromSession() {
                                echo _("Renewing").": ".$row['CN']."<br>\n";
                                $res = mysql_query("select * from `orgdomlink` where `orgcertid`='".$row['id']."'");
                                while($r2 = mysql_fetch_assoc($res))
-                                       mysql_query("insert into `orgdomlink` set `orgdomid`='".$r2['id']."', `orgcertid`='$newid'");
+                                       mysql_query("insert into `orgdomlink` set `orgdomid`='".intval($r2['orgdomid'])."', `orgcertid`='$newid'");
                                waitForResult("orgdomaincerts", $newid,$oldid,0);
                                $query = "select * from `orgdomaincerts` where `id`='$newid' and `crt_name` != ''";
                                $res = mysql_query($query);