edit.php
changeset 3 64525a2eb098
parent 2 9a485c41cfcf
child 5 ebf8868e99f5
equal deleted inserted replaced
2:9a485c41cfcf 3:64525a2eb098
    53 <?
    53 <?
    54 $info = get_domain_info_from_id($_GET["id"]);
    54 $info = get_domain_info_from_id($_GET["id"]);
    55 if(!isset($info["ownerid"]))
    55 if(!isset($info["ownerid"]))
    56 {
    56 {
    57 	?>
    57 	?>
    58 	<P CLASS="warning"><? echo _('This domain isnt owned by anyone yet, please assign someone.'); ?></P>
    58 	<P CLASS="warning"><? echo _('This domain isn\'t owned by anyone yet, please assign someone.'); ?></P>
    59 	<?
    59 	<?
    60 }
    60 }
    61 ?>
    61 ?>
    62 
    62 
    63 <TABLE class="text" cellspacing="0" style="width: 280px">
    63 <TABLE class="text" cellspacing="0" style="width: 280px">
    83 			}
    83 			}
    84 			?>
    84 			?>
    85 			</SELECT>
    85 			</SELECT>
    86 		</TD>
    86 		</TD>
    87 		<TD CLASS="none" VALIGN="middle"  align="right">
    87 		<TD CLASS="none" VALIGN="middle"  align="right">
    88 			<INPUT TYPE="submit" CLASS="sbutton" NAME="co" VALUE="<? echo _('add'); ?>">
    88 			<INPUT TYPE="submit" CLASS="sbutton" NAME="co" VALUE="<? echo _('Add'); ?>">
    89 		</TD>
    89 		</TD>
    90 		</FORM>
    90 		</FORM>
    91 	</TR>
    91 	</TR>
    92 	<TR>
    92 	<TR>
    93 		<TD CLASS="text">&nbsp;</TD>
    93 		<TD CLASS="text" COLSPAN="2">&nbsp;</TD>
    94 	</TR>
    94 	</TR>
    95 <? 
    95 <? 
    96 
    96 
    97 if(isset($info["ownerid"]))
    97 if(isset($info["ownerid"]))
    98 {?>
    98 {?>
   110 			<TD CLASS="text" ALIGN="left" style="width:150px;">
   110 			<TD CLASS="text" ALIGN="left" style="width:150px;">
   111 				<?=$user["fullname"]?>
   111 				<?=$user["fullname"]?>
   112 			</TD>
   112 			</TD>
   113 			<TD CLASS="text" align="right">
   113 			<TD CLASS="text" align="right">
   114 				<INPUT TYPE="hidden" NAME="del_user" VALUE="<?=$user["id"]?>">
   114 				<INPUT TYPE="hidden" NAME="del_user" VALUE="<?=$user["id"]?>">
   115 				<INPUT TYPE="submit" CLASS="sbutton" NAME="co" VALUE="<? echo _('delete'); ?>">
   115 				<INPUT TYPE="submit" CLASS="sbutton" NAME="co" VALUE="<? echo _('Delete'); ?>">
   116 			</TD>
   116 			</TD>
   117 			</FORM>
   117 			</FORM>
   118 		</TR>
   118 		</TR>
   119 	<? }
   119 	<? }
   120 }} ?>
   120 }} ?>
   147                 }
   147                 }
   148                 ?>
   148                 ?>
   149                 </SELECT>
   149                 </SELECT>
   150             </TD>
   150             </TD>
   151             <TD CLASS="text">
   151             <TD CLASS="text">
   152                 <INPUT TYPE="submit" CLASS="sbutton" NAME="type_change" VALUE="<? echo _('change'); ?>">
   152                 <INPUT TYPE="submit" CLASS="sbutton" NAME="type_change" VALUE="<? echo _('Change'); ?>">
   153             </TD>
   153             </TD>
   154         </TR>
   154         </TR>
   155         </FORM>
   155         </FORM>
   156 <? } ?>
   156 <? } ?>
   157 </TABLE>
   157 </TABLE>
   180 if($rec_result != -1)
   180 if($rec_result != -1)
   181 {
   181 {
   182 	?>
   182 	?>
   183 	<TR STYLE="font-weight: Bold;">
   183 	<TR STYLE="font-weight: Bold;">
   184 	<TD CLASS="tdbg">&nbsp;</TD>
   184 	<TD CLASS="tdbg">&nbsp;</TD>
   185 	<? if (level(10)) { echo "<TD CLASS=\"tdbg\">" . _('Sub-Owners') . "</TD>"; } ?>
   185 	<? if (level(10)) { echo "<TD CLASS=\"tdbg\">" . _('Sub-owners') . "</TD>"; } ?>
   186 	<TD CLASS="tdbg"><? echo _('Name'); ?></TD>
   186 	<TD CLASS="tdbg"><? echo _('Name'); ?></TD>
   187 	<TD CLASS="tdbg"><? echo _('Type'); ?></TD>
   187 	<TD CLASS="tdbg"><? echo _('Type'); ?></TD>
   188 	<TD CLASS="tdbg"><? echo _('Content'); ?></TD>
   188 	<TD CLASS="tdbg"><? echo _('Content'); ?></TD>
   189 	<TD CLASS="tdbg"><? echo _('Priority'); ?></TD>
   189 	<TD CLASS="tdbg"><? echo _('Priority'); ?></TD>
   190 	<TD CLASS="tdbg"><? echo _('TTL'); ?></TD>
   190 	<TD CLASS="tdbg"><? echo _('TTL'); ?></TD>
   197 
   197 
   198 	        if(level(5) || (!($r["type"] == "SOA" && !$GLOBALS["ALLOW_SOA_EDIT"]) && !($r["type"] == "NS" && !$GLOBALS["ALLOW_NS_EDIT"])))
   198 	        if(level(5) || (!($r["type"] == "SOA" && !$GLOBALS["ALLOW_SOA_EDIT"]) && !($r["type"] == "NS" && !$GLOBALS["ALLOW_NS_EDIT"])))
   199 	        {
   199 	        {
   200                 // get_name_from_record_id($r["id"]) != get_domain_name_from_id(recid_to_domid($r["id"])) <-- hmm..
   200                 // get_name_from_record_id($r["id"]) != get_domain_name_from_id(recid_to_domid($r["id"])) <-- hmm..
   201                 ?>
   201                 ?>
   202 	            <A HREF="edit_record.php?id=<?= $r['id'] ?>&amp;domain=<?= $_GET["id"] ?>"><IMG SRC="images/edit.gif" ALT="[ <? echo _('edit record'); ?> ]" BORDER="0"></A>
   202 	            <A HREF="edit_record.php?id=<?= $r['id'] ?>&amp;domain=<?= $_GET["id"] ?>"><IMG SRC="images/edit.gif" ALT="[ <? echo _('Edit record'); ?> ]" BORDER="0"></A>
   203 	            <A HREF="delete_record.php?id=<?= $r['id'] ?>&amp;domain=<?= $_GET["id"] ?>"><IMG SRC="images/delete.gif" ALT="[ <? echo _('delete record'); ?> ]" BORDER="0"></A>
   203 	            <A HREF="delete_record.php?id=<?= $r['id'] ?>&amp;domain=<?= $_GET["id"] ?>"><IMG SRC="images/delete.gif" ALT="[ <? echo _('Delete record'); ?> ]" BORDER="0"></A>
   204 	            <?
   204 	            <?
   205 	        }
   205 	        }
   206 
   206 
   207 if(level(10)) { ?>
   207 if(level(10)) { ?>
   208 
   208