bug 1138: only show "change comment" check boxes when not read only
authorMichael Tänzer <neo@nhng.de>
Mon, 7 Apr 2014 14:59:06 +0000 (16:59 +0200)
committerMichael Tänzer <neo@nhng.de>
Mon, 7 Apr 2014 14:59:06 +0000 (16:59 +0200)
Signed-off-by: Michael Tänzer <neo@nhng.de>
includes/notary.inc.php

index 1518d4e..7224414 100644 (file)
@@ -1736,10 +1736,14 @@ function output_client_cert($row, $support=0, $readonly=true){
                <td class="DataTD">
                        <input name="comment_<?=$row['id']?>" type="text" value="<?=htmlspecialchars($row['description'])?>" />
                </td>
-               <td class="DataTD">
-                       <input type="checkbox" name="check_comment_<?=$row['id']?>" />
-               </td>
                <?
+               if (!$readonly) {
+                       ?>
+                       <td class="DataTD">
+                               <input type="checkbox" name="check_comment_<?=$row['id']?>" />
+                       </td>
+                       <?
+               }
        }
 
        ?>