本文整理匯總了PHP中networking::BuildResolvConf方法的典型用法代碼示例。如果您正苦於以下問題:PHP networking::BuildResolvConf方法的具體用法?PHP networking::BuildResolvConf怎麽用?PHP networking::BuildResolvConf使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類networking
的用法示例。
在下文中一共展示了networking::BuildResolvConf方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: NicNameServerMove
function NicNameServerMove()
{
$index = $_GET["NicNameServerMove"];
$move = $_GET["move"];
$nic = new networking();
$newarray = array_move_element($nic->arrayNameServers, $nic->arrayNameServers[$index], $move);
$nic->BuildResolvConf();
}
示例2: save_nic
function save_nic()
{
$nic = trim($_GET["save_nic"]);
$IPADDR = trim($_GET["IPADDR"]);
$NETMASK = trim($_GET["NETMASK"]);
$GATEWAY = trim($_GET["GATEWAY"]);
$DNS_1 = $_GET["DNS_1"];
$DNS_2 = $_GET["DNS_2"];
$dhcp = trim($_GET["dhcp"]);
writelogs("save nic infos : {$nic};{$IPADDR};{$NETMASK};{$GATEWAY};{$dhcp}", __FUNCTION__, __FILE__);
$ip = new networking();
$ip->nameserver_add($DNS_1);
if (trim($DNS_2) != null) {
$ip->nameserver_add($DNS_2);
}
$ip->BuildResolvConf();
$sock = new sockets();
$sock->getFrameWork("cmd.php?SaveNic={$nic}&ip={$IPADDR}&net={$NETMASK}&gw={$GATEWAY}&dhcp={$dhcp}");
$tpl = new templates();
echo $tpl->_ENGINE_parse_body('{success}\\n{success_save_nic_infos}');
}