[feladat @ 80]
Re-added link to credits (was removed by accident as well).
<?phprequire_once("inc/i18n.inc.php");require_once("inc/toolkit.inc.php");if(!level(5)){error(ERR_LEVEL_5);}if($_POST["submit"]){$master_ip=$_POST["master_ip"];$ns_name=$_POST["ns_name"];$account=$_POST["account"];if(!$error){if(!is_valid_ip($master_ip)&&!is_valid_ip6($master_ip)){$error=_('Given master IP address is not valid IPv4 or IPv6.');}elseif(!is_valid_hostname($ns_name)){$error=_('Given hostname for NS record not valid.');}elseif(!validate_account($account)){$error=_('Account name is not valid (may contain only alpha chars).');}else{if(add_supermaster($master_ip,$ns_name,$account)){$success=_('Successfully added supermaster.');}}}}include_once("inc/header.inc.php");if($error!=""){?><divclass="error"><?echo_('Error');?>:<?echo$error;?></div><?}elseif($success!=""){?><divclass="success"><?echo$success;?></div><?}?><h2><?echo_('Add supermaster');?></h2><formmethod="post"action="add_supermaster.php"><table><tr><tdclass="n"><?echo_('IP address of supermaster');?>:</td><tdclass="n"><inputtype="text"class="input"name="master_ip"value="<?if($error)print$_POST["master_ip"];?>"></td></tr><tr><tdclass="n"><?echo_('Hostname in NS record');?>:</td><tdclass="n"><inputtype="text"class="input"name="ns_name"value="<?if($error)print$_POST["ns_name"];?>"></td></tr><tr><tdclass="n"><?echo_('Account');?>:</td><tdclass="n"><inputtype="text"class="input"name="account"value="<?if($error)print$_POST["account"];?>"></td></tr><tr><tdclass="n"> </td><tdclass="n"><inputtype="submit"class="button"name="submit"value="<?echo_('Add supermaster');?>"></td></tr></table></form><?include_once("inc/footer.inc.php");?>