diff options
Diffstat (limited to 'usr/local/www')
-rwxr-xr-x | usr/local/www/services_dyndns.php | 24 |
1 files changed, 3 insertions, 21 deletions
diff --git a/usr/local/www/services_dyndns.php b/usr/local/www/services_dyndns.php index 2d209c1..a80b6ae 100755 --- a/usr/local/www/services_dyndns.php +++ b/usr/local/www/services_dyndns.php @@ -1,7 +1,7 @@ <?php /* $Id$ */ /* - Copyright (C) 2008 Ermal Luçi + Copyright (C) 2008 Ermal Luçi All rights reserved. Redistribution and use in source and binary forms, with or without @@ -61,24 +61,6 @@ if ($_GET['act'] == "del") { exit; } -function dyndnsCheckIP($int) { - $ip_address = get_interface_ip($int); - if (is_private_ip($ip_address)) { - $hosttocheck = "checkip.dyndns.org"; - $checkip = gethostbyname($hosttocheck); - $ip_ch = curl_init("http://{$checkip}"); - curl_setopt($ip_ch, CURLOPT_RETURNTRANSFER, 1); - curl_setopt($ip_ch, CURLOPT_SSL_VERIFYPEER, FALSE); - curl_setopt($ip_ch, CURLOPT_INTERFACE, $ip_address); - $ip_result_page = curl_exec($ip_ch); - curl_close($ip_ch); - $ip_result_decoded = urldecode($ip_result_page); - preg_match('=Current IP Address: (.*)</body>=siU', $ip_result_decoded, $matches); - $ip_address = trim($matches[1]); - } - return $ip_address; -} - $pgtitle = array(gettext("Services"), gettext("Dynamic DNS clients")); include("head.inc"); @@ -138,8 +120,8 @@ include("head.inc"); </td> <td class="listr"> <?php - $types = explode(",", "DNS-O-Matic, DynDNS (dynamic),DynDNS (static),DynDNS (custom),DHS,DyNS,easyDNS,No-IP,ODS.org,ZoneEdit,Loopia,freeDNS, DNSexit, OpenDNS, Namecheap, HE.net, HE.net Tunnelbroker, SelfHost, Route 53, Custom"); - $vals = explode(" ", "dnsomatic dyndns dyndns-static dyndns-custom dhs dyns easydns noip ods zoneedit loopia freedns dnsexit opendns namecheap he-net he-net-tunnelbroker selfhost route53 custom"); + $types = explode(",", DYNDNS_PROVIDER_DESCRIPTIONS); + $vals = explode(" ", DYNDNS_PROVIDER_VALUES); for ($j = 0; $j < count($vals); $j++) if ($vals[$j] == $dyndns['type']) { if (!isset($dyndns['enable'])) |