Revision 20db3e1a
Added by Phil Davis over 9 years ago
src/usr/local/www/services_rfc2136.php | ||
---|---|---|
75 | 75 |
|
76 | 76 |
header("Location: services_rfc2136.php"); |
77 | 77 |
exit; |
78 |
} |
|
79 |
else if ($_GET['act'] == "toggle") { |
|
78 |
} else if ($_GET['act'] == "toggle") { |
|
80 | 79 |
if ($a_rfc2136[$_GET['id']]) { |
81 | 80 |
if (isset($a_rfc2136[$_GET['id']]['enable'])) { |
82 | 81 |
unset($a_rfc2136[$_GET['id']]['enable']); |
... | ... | |
98 | 97 |
$tab_array[] = array(gettext("RFC 2136"), true, "services_rfc2136.php"); |
99 | 98 |
display_top_tabs($tab_array); |
100 | 99 |
|
101 |
if ($input_errors) |
|
100 |
if ($input_errors) {
|
|
102 | 101 |
print_input_errors($input_errors); |
102 |
} |
|
103 | 103 |
?> |
104 | 104 |
|
105 | 105 |
<form action="services_rfc2136.php" method="post" name="iform" id="iform"> |
... | ... | |
147 | 147 |
|
148 | 148 |
if (file_exists($filename)) { |
149 | 149 |
print('IPv4: '); |
150 |
if (isset($rfc2136['usepublicip'])) |
|
150 |
if (isset($rfc2136['usepublicip'])) {
|
|
151 | 151 |
$ipaddr = dyndnsCheckIP($rfc2136['interface']); |
152 |
else
|
|
152 |
} else {
|
|
153 | 153 |
$ipaddr = get_interface_ip($rfc2136['interface']); |
154 |
} |
|
154 | 155 |
|
155 | 156 |
$cached_ip_s = explode("|", file_get_contents($filename)); |
156 | 157 |
$cached_ip = $cached_ip_s[0]; |
157 | 158 |
|
158 |
if ($ipaddr != $cached_ip) |
|
159 |
if ($ipaddr != $cached_ip) {
|
|
159 | 160 |
print('<span class="text-danger">'); |
160 |
else
|
|
161 |
} else {
|
|
161 | 162 |
print('<span class="text-success">'); |
163 |
} |
|
162 | 164 |
|
163 | 165 |
print(htmlspecialchars($cached_ip)); |
164 | 166 |
print('</span>'); |
... | ... | |
174 | 176 |
$cached_ip_s = explode("|", file_get_contents("{$filename}.ipv6")); |
175 | 177 |
$cached_ip = $cached_ip_s[0]; |
176 | 178 |
|
177 |
if ($ipaddr != $cached_ip) |
|
179 |
if ($ipaddr != $cached_ip) {
|
|
178 | 180 |
print('<span class="text-danger">'); |
179 |
else
|
|
181 |
} else {
|
|
180 | 182 |
print('<span class="text-success">'); |
183 |
} |
|
181 | 184 |
|
182 | 185 |
print(htmlspecialchars($cached_ip)); |
183 | 186 |
print('</span>'); |
Also available in: Unified diff
Code style services