Project

General

Profile

Download (17.5 KB) Statistics
| Branch: | Tag: | Revision:
1 5b237745 Scott Ullrich
<?php
2 b46bfcf5 Bill Marquette
/* $Id$ */
3 5b237745 Scott Ullrich
/*
4
	services_dnsmasq.php
5
	part of m0n0wall (http://m0n0.ch/wall)
6 f0fe3d30 Scott Ullrich
7 5b237745 Scott Ullrich
	Copyright (C) 2003-2004 Bob Zoller <bob@kludgebox.com> and Manuel Kasper <mk@neon1.net>.
8
	All rights reserved.
9 f0fe3d30 Scott Ullrich
10 5b237745 Scott Ullrich
	Redistribution and use in source and binary forms, with or without
11
	modification, are permitted provided that the following conditions are met:
12 f0fe3d30 Scott Ullrich
13 5b237745 Scott Ullrich
	1. Redistributions of source code must retain the above copyright notice,
14
	   this list of conditions and the following disclaimer.
15 f0fe3d30 Scott Ullrich
16 5b237745 Scott Ullrich
	2. Redistributions in binary form must reproduce the above copyright
17
	   notice, this list of conditions and the following disclaimer in the
18
	   documentation and/or other materials provided with the distribution.
19 f0fe3d30 Scott Ullrich
20 5b237745 Scott Ullrich
	THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
21
	INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
22
	AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
23
	AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
24
	OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
25
	SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
26
	INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
27
	CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
28
	ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
29
	POSSIBILITY OF SUCH DAMAGE.
30
*/
31 70edf50d jim-p
/*
32 1d333258 Scott Ullrich
	pfSense_MODULE:	dnsforwarder
33
*/
34 5b237745 Scott Ullrich
35 6b07c15a Matthew Grooms
##|+PRIV
36
##|*IDENT=page-services-dnsforwarder
37
##|*NAME=Services: DNS Forwarder page
38
##|*DESCR=Allow access to the 'Services: DNS Forwarder' page.
39
##|*MATCH=services_dnsmasq.php*
40
##|-PRIV
41
42 5b237745 Scott Ullrich
require("guiconfig.inc");
43 7a927e67 Scott Ullrich
require_once("functions.inc");
44
require_once("filter.inc");
45
require_once("shaper.inc");
46 5b237745 Scott Ullrich
47 70edf50d jim-p
$pconfig['enable'] = isset($config['dnsmasq']['enable']);
48 5b237745 Scott Ullrich
$pconfig['regdhcp'] = isset($config['dnsmasq']['regdhcp']);
49 6a01ea44 Bill Marquette
$pconfig['regdhcpstatic'] = isset($config['dnsmasq']['regdhcpstatic']);
50 aa994814 Andrew Thompson
$pconfig['dhcpfirst'] = isset($config['dnsmasq']['dhcpfirst']);
51 96ea7162 N0YB
$pconfig['strict_order'] = isset($config['dnsmasq']['strict_order']);
52
$pconfig['domain_needed'] = isset($config['dnsmasq']['domain_needed']);
53 7bdd28fb Phil Davis
$pconfig['no_private_reverse'] = isset($config['dnsmasq']['no_private_reverse']);
54 8f9bffbc Andrew Thompson
$pconfig['custom_options'] = $config['dnsmasq']['custom_options'];
55 5b237745 Scott Ullrich
56 70edf50d jim-p
if (!is_array($config['dnsmasq']['hosts']))
57 5b237745 Scott Ullrich
	$config['dnsmasq']['hosts'] = array();
58 0c2b5df7 Scott Ullrich
59 70edf50d jim-p
if (!is_array($config['dnsmasq']['domainoverrides']))
60
	$config['dnsmasq']['domainoverrides'] = array();
61 0c2b5df7 Scott Ullrich
62 4d6ba181 Scott Ullrich
63 70edf50d jim-p
$a_hosts = &$config['dnsmasq']['hosts'];
64 0c2b5df7 Scott Ullrich
$a_domainOverrides = &$config['dnsmasq']['domainoverrides'];
65 5b237745 Scott Ullrich
66
if ($_POST) {
67
68
	$pconfig = $_POST;
69 8f9bffbc Andrew Thompson
	unset($input_errors);
70 5b237745 Scott Ullrich
71
	$config['dnsmasq']['enable'] = ($_POST['enable']) ? true : false;
72
	$config['dnsmasq']['regdhcp'] = ($_POST['regdhcp']) ? true : false;
73 6a01ea44 Bill Marquette
	$config['dnsmasq']['regdhcpstatic'] = ($_POST['regdhcpstatic']) ? true : false;
74 aa994814 Andrew Thompson
	$config['dnsmasq']['dhcpfirst'] = ($_POST['dhcpfirst']) ? true : false;
75 96ea7162 N0YB
	$config['dnsmasq']['strict_order'] = ($_POST['strict_order']) ? true : false;
76
	$config['dnsmasq']['domain_needed'] = ($_POST['domain_needed']) ? true : false;
77 7bdd28fb Phil Davis
	$config['dnsmasq']['no_private_reverse'] = ($_POST['no_private_reverse']) ? true : false;
78 8f9bffbc Andrew Thompson
	$config['dnsmasq']['custom_options'] = str_replace("\r\n", "\n", $_POST['custom_options']);
79
80
	if ($config['dnsmasq']['custom_options']) {
81
		$args = '';
82
		foreach (preg_split('/\s+/', $config['dnsmasq']['custom_options']) as $c)
83
			$args .= "--$c ";
84
		exec("/usr/local/sbin/dnsmasq --test $args", $output, $rc);
85
		if ($rc != 0)
86
			$input_errors[] = gettext("Invalid custom options");
87
	}
88 5b237745 Scott Ullrich
89 8f9bffbc Andrew Thompson
	if (!$input_errors) {
90
		write_config();
91 f0fe3d30 Scott Ullrich
92 8f9bffbc Andrew Thompson
		$retval = 0;
93
		$retval = services_dnsmasq_configure();
94
		$savemsg = get_std_save_message($retval);
95 5b237745 Scott Ullrich
96 8f9bffbc Andrew Thompson
		// Relaod filter (we might need to sync to CARP hosts)
97
		filter_configure();
98 020d757a Scott Ullrich
99 8f9bffbc Andrew Thompson
		if ($retval == 0)
100
			clear_subsystem_dirty('hosts');
101
	}
102 5b237745 Scott Ullrich
}
103
104
if ($_GET['act'] == "del") {
105 70edf50d jim-p
	if ($_GET['type'] == 'host') {
106
		if ($a_hosts[$_GET['id']]) {
107
			unset($a_hosts[$_GET['id']]);
108
			write_config();
109 a368a026 Ermal Lu?i
			mark_subsystem_dirty('hosts');
110 70edf50d jim-p
			header("Location: services_dnsmasq.php");
111
			exit;
112
		}
113
	}
114
	elseif ($_GET['type'] == 'doverride') {
115
		if ($a_domainOverrides[$_GET['id']]) {
116
			unset($a_domainOverrides[$_GET['id']]);
117
			write_config();
118 a368a026 Ermal Lu?i
			mark_subsystem_dirty('hosts');
119 70edf50d jim-p
			header("Location: services_dnsmasq.php");
120
			exit;
121
		}
122
	}
123 5b237745 Scott Ullrich
}
124 0c2b5df7 Scott Ullrich
125 beb2bc00 Rafael Lucas
$pgtitle = array(gettext("Services"),gettext("DNS forwarder"));
126 b32dd0a6 jim-p
$shortcut_section = "resolver";
127 b63695db Scott Ullrich
include("head.inc");
128 0c2b5df7 Scott Ullrich
129 5b237745 Scott Ullrich
?>
130
131 6a01ea44 Bill Marquette
<script language="JavaScript">
132
<!--
133
function enable_change(enable_over) {
134
	var endis;
135
	endis = !(document.iform.enable.checked || enable_over);
136
	document.iform.regdhcp.disabled = endis;
137
	document.iform.regdhcpstatic.disabled = endis;
138 aa994814 Andrew Thompson
	document.iform.dhcpfirst.disabled = endis;
139 6a01ea44 Bill Marquette
}
140 8f9bffbc Andrew Thompson
function show_advanced_dns() {
141
	document.getElementById("showadvbox").innerHTML='';
142
	aodiv = document.getElementById('showadv');
143
	aodiv.style.display = "block";
144
}
145 6a01ea44 Bill Marquette
//-->
146
</script>
147
148 5b237745 Scott Ullrich
<body link="#0000CC" vlink="#0000CC" alink="#0000CC">
149
<?php include("fbegin.inc"); ?>
150 6a01ea44 Bill Marquette
<form action="services_dnsmasq.php" method="post" name="iform" id="iform">
151 8f9bffbc Andrew Thompson
<?php if ($input_errors) print_input_errors($input_errors); ?>
152 5b237745 Scott Ullrich
<?php if ($savemsg) print_info_box($savemsg); ?>
153 a368a026 Ermal Lu?i
<?php if (is_subsystem_dirty('hosts')): ?><p>
154 619c72f9 Carlos Eduardo Ramos
<?php print_info_box_np(gettext("The DNS forwarder configuration has been changed") . ".<br>" . gettext("You must apply the changes in order for them to take effect."));?><br>
155 5b237745 Scott Ullrich
<?php endif; ?>
156 70edf50d jim-p
<table width="100%" border="0" cellpadding="6" cellspacing="0">
157
	<tr>
158 6661dbcf jim-p
		<td colspan="2" valign="top" class="listtopic"><?=gettext("General DNS Forwarder Options");?></td>
159
	</tr>
160
	<tr>
161
		<td width="22%" valign="top" class="vncellreq"><?=gettext("Enable");?></td>
162
		<td width="78%" class="vtable"><p>
163 70edf50d jim-p
			<input name="enable" type="checkbox" id="enable" value="yes" <?php if ($pconfig['enable'] == "yes") echo "checked";?> onClick="enable_change(false)">
164
			<strong><?=gettext("Enable DNS forwarder");?><br>
165
			</strong></p></td>
166 98776e04 jim-p
		</tr>
167 70edf50d jim-p
	<tr>
168 6661dbcf jim-p
		<td width="22%" valign="top" class="vncellreq"><?=gettext("DHCP Registration");?></td>
169
		<td width="78%" class="vtable"><p>
170 70edf50d jim-p
			<input name="regdhcp" type="checkbox" id="regdhcp" value="yes" <?php if ($pconfig['regdhcp'] == "yes") echo "checked";?>>
171
			<strong><?=gettext("Register DHCP leases in DNS forwarder");?><br>
172
			</strong><?php printf(gettext("If this option is set, then machines that specify".
173
			" their hostname when requesting a DHCP lease will be registered".
174
			" in the DNS forwarder, so that their name can be resolved.".
175
			" You should also set the domain in %sSystem:".
176
			" General setup%s to the proper value."),'<a href="system.php">','</a>')?></p>
177
		</td>
178
	</tr>
179
	<tr>
180 6661dbcf jim-p
		<td width="22%" valign="top" class="vncellreq"><?=gettext("Static DHCP");?></td>
181
		<td width="78%" class="vtable"><p>
182 70edf50d jim-p
			<input name="regdhcpstatic" type="checkbox" id="regdhcpstatic" value="yes" <?php if ($pconfig['regdhcpstatic'] == "yes") echo "checked";?>>
183
			<strong><?=gettext("Register DHCP static mappings in DNS forwarder");?><br>
184
			</strong><?php printf(gettext("If this option is set, then DHCP static mappings will ".
185
					"be registered in the DNS forwarder, so that their name can be ".
186
					"resolved. You should also set the domain in %s".
187
					"System: General setup%s to the proper value."),'<a href="system.php">','</a>');?></p>
188
		</td>
189
	</tr>
190 aa994814 Andrew Thompson
	<tr>
191 6661dbcf jim-p
		<td width="22%" valign="top" class="vncellreq"><?=gettext("Prefer DHCP");?></td>
192
		<td width="78%" class="vtable"><p>
193 aa994814 Andrew Thompson
			<input name="dhcpfirst" type="checkbox" id="dhcpfirst" value="yes" <?php if ($pconfig['dhcpfirst'] == "yes") echo "checked";?>>
194
			<strong><?=gettext("Resolve DHCP mappings first");?><br>
195
			</strong><?php printf(gettext("If this option is set, then DHCP mappings will ".
196
					"be resolved before the manual list of names below. This only ".
197 649ea752 Andrew Thompson
					"affects the name given for a reverse lookup (PTR)."));?></p>
198 aa994814 Andrew Thompson
		</td>
199
	</tr>
200 96ea7162 N0YB
	<tr>
201 7bdd28fb Phil Davis
		<td rowspan="3" width="22%" valign="top" class="vncellreq"><?=gettext("DNS Query Forwarding");?></td>
202 96ea7162 N0YB
		<td width="78%" class="vtable"><p>
203
			<input name="strict_order" type="checkbox" id="strict_order" value="yes" <?php if ($pconfig['strict_order'] == "yes") echo "checked";?>>
204
			<strong><?=gettext("Query DNS servers sequentially");?><br>
205
			</strong><?php printf(gettext("If this option is set, %s DNS Forwarder (dnsmasq) will ".
206
					"query the DNS servers sequentially in the order specified (<i>System - General Setup - DNS Servers</i>), ".
207
					"rather than all at once in parallel. ".
208
					""), $g['product_name']); ?></p>
209
		</td>
210
	</tr>
211
	<tr>
212
		<td width="78%" class="vtable"><p>
213
			<input name="domain_needed" type="checkbox" id="domain_needed" value="yes" <?php if ($pconfig['domain_needed'] == "yes") echo "checked";?>>
214
			<strong><?=gettext("Require domain");?><br>
215
			</strong><?php printf(gettext("If this option is set, %s DNS Forwarder (dnsmasq) will ".
216
					"not forward A or AAAA queries for plain names, without dots or domain parts, to upstream name servers.  ".
217
					"If the name is not known from /etc/hosts or DHCP then a \"not found\" answer is returned. ".
218
					""), $g['product_name']); ?></p>
219
		</td>
220
	</tr>
221 7bdd28fb Phil Davis
	<tr>
222
		<td width="78%" class="vtable"><p>
223
			<input name="no_private_reverse" type="checkbox" id="no_private_reverse" value="yes" <?php if ($pconfig['no_private_reverse'] == "yes") echo "checked";?>>
224
			<strong><?=gettext("Do not forward private reverse lookups");?><br>
225
			</strong><?php printf(gettext("If this option is set, %s DNS Forwarder (dnsmasq) will ".
226
					"not forward reverse DNS lookups (PTR) for private addresses (RFC 1918) to upstream name servers.  ".
227
					"Any entries in the Domain Overrides section forwarding private \"n.n.n.in-addr.arpa\" names to a specific server are still forwarded. ".
228
					"If the IP to name is not known from /etc/hosts, DHCP or a specific domain override then a \"not found\" answer is immediately returned. ".
229
					""), $g['product_name']); ?></p>
230
		</td>
231
	</tr>
232 8f9bffbc Andrew Thompson
	<tr>
233 6661dbcf jim-p
		<td width="22%" valign="top" class="vncellreq"><?=gettext("Advanced");?></td>
234
		<td width="78%" class="vtable"><p>
235 8f9bffbc Andrew Thompson
			<div id="showadvbox" <?php if ($pconfig['custom_options']) echo "style='display:none'"; ?>>
236
				<input type="button" onClick="show_advanced_dns()" value="<?=gettext("Advanced"); ?>"></input> - <?=gettext("Show advanced option");?></a>
237
			</div>
238
			<div id="showadv" <?php if (empty($pconfig['custom_options'])) echo "style='display:none'"; ?>>
239
				<strong><?=gettext("Advanced");?><br></strong>
240
				<textarea rows="6" cols="78" name="custom_options" id="custom_options"><?=htmlspecialchars($pconfig['custom_options']);?></textarea><br/>
241
				<?=gettext("Enter any additional options you would like to add to the dnsmasq configuration here, separated by a space or newline"); ?><br/>
242
			</div>
243
			</p>
244
		</td>
245
	</tr>
246 70edf50d jim-p
	<tr>
247 6661dbcf jim-p
		<td colspan="2">
248 70edf50d jim-p
			<input name="submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>" onclick="enable_change(true)">
249
		</td>
250
	</tr>
251
</table>
252 6661dbcf jim-p
253
<p><span class="vexpl"><span class="red"><strong><?=gettext("Note:");?><br>
254
</strong></span><?php printf(gettext("If the DNS forwarder is enabled, the DHCP".
255
" service (if enabled) will automatically serve the LAN IP".
256
" address as a DNS server to DHCP clients so they will use".
257
" the forwarder. The DNS forwarder will use the DNS servers".
258
" entered in %sSystem: General setup%s".
259
" or those obtained via DHCP or PPP on WAN if the &quot;Allow".
260
" DNS server list to be overridden by DHCP/PPP on WAN&quot;".
261
" is checked. If you don't use that option (or if you use".
262
" a static IP address on WAN), you must manually specify at".
263
" least one DNS server on the %sSystem:".
264
"General setup%s page."),'<a href="system.php">','</a>','<a href="system.php">','</a>');?><br>
265
</span></p>
266
267 70edf50d jim-p
&nbsp;<br>
268 6661dbcf jim-p
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont">
269
<tr>
270
	<td colspan="5" valign="top" class="listtopic"><?=gettext("Host Overrides");?></td>
271
</tr>
272
<tr>
273
	<td><br/>
274
	<?=gettext("Entries in this section override individual results from the forwarders.");?>
275
	<?=gettext("Use these for changing DNS results or for adding custom DNS records.");?>
276
	</td>
277
</tr>
278
</table>
279
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont sortable">
280 70edf50d jim-p
	<thead>
281
	<tr>
282
		<td width="20%" class="listhdrr"><?=gettext("Host");?></td>
283
		<td width="25%" class="listhdrr"><?=gettext("Domain");?></td>
284
		<td width="20%" class="listhdrr"><?=gettext("IP");?></td>
285
		<td width="25%" class="listhdr"><?=gettext("Description");?></td>
286
		<td width="10%" class="list">
287 d415d821 Seth Mos
			<table border="0" cellspacing="0" cellpadding="1">
288 70edf50d jim-p
				<tr>
289
					<td width="17"></td>
290
					<td valign="middle"><a href="services_dnsmasq_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td>
291
				</tr>
292 d415d821 Seth Mos
			</table>
293 70edf50d jim-p
		</td>
294
	</tr>
295
	</thead>
296
	<tbody>
297
	<?php $i = 0; foreach ($a_hosts as $hostent): ?>
298
	<tr>
299
		<td class="listlr" ondblclick="document.location='services_dnsmasq_edit.php?id=<?=$i;?>';">
300
			<?=strtolower($hostent['host']);?>&nbsp;
301
		</td>
302
		<td class="listr" ondblclick="document.location='services_dnsmasq_edit.php?id=<?=$i;?>';">
303
			<?=strtolower($hostent['domain']);?>&nbsp;
304
		</td>
305
		<td class="listr" ondblclick="document.location='services_dnsmasq_edit.php?id=<?=$i;?>';">
306
			<?=$hostent['ip'];?>&nbsp;
307
		</td>
308
		<td class="listbg" ondblclick="document.location='services_dnsmasq_edit.php?id=<?=$i;?>';">
309
			<?=htmlspecialchars($hostent['descr']);?>&nbsp;
310
		</td>
311
		<td valign="middle" nowrap class="list">
312 d415d821 Seth Mos
			<table border="0" cellspacing="0" cellpadding="1">
313 70edf50d jim-p
				<tr>
314
					<td valign="middle"><a href="services_dnsmasq_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a></td>
315
					<td><a href="services_dnsmasq.php?type=host&act=del&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this host?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
316
				</tr>
317 d415d821 Seth Mos
			</table>
318 70edf50d jim-p
	</tr>
319 e37eeb49 jim-p
	<?php if ($hostent['aliases']['item'] && is_array($hostent['aliases']['item'])): ?>
320 5a2a8349 Lorenz Schori
	<?php foreach ($hostent['aliases']['item'] as $alias): ?>
321
	<tr>
322
		<td class="listlr" ondblclick="document.location='services_dnsmasq_edit.php?id=<?=$i;?>';">
323
			<?=strtolower($alias['host']);?>&nbsp;
324
		</td>
325
		<td class="listr" ondblclick="document.location='services_dnsmasq_edit.php?id=<?=$i;?>';">
326
			<?=strtolower($alias['domain']);?>&nbsp;
327
		</td>
328
		<td class="listr" ondblclick="document.location='services_dnsmasq_edit.php?id=<?=$i;?>';">
329
			Alias for <?=$hostent['host'] ? $hostent['host'] . '.' . $hostent['domain'] : $hostent['domain'];?>&nbsp;
330
		</td>
331
		<td class="listbg" ondblclick="document.location='services_dnsmasq_edit.php?id=<?=$i;?>';">
332
			<?=htmlspecialchars($alias['description']);?>&nbsp;
333
		</td>
334
		<td valign="middle" nowrap class="list">
335
			<a href="services_dnsmasq_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a>
336
		</td>
337
	</tr>
338
	<?php endforeach; ?>
339 e37eeb49 jim-p
	<?php endif; ?>
340 70edf50d jim-p
	<?php $i++; endforeach; ?>
341
	</tbody>
342
	<tfoot>
343
	<tr>
344
		<td class="list" colspan="4"></td>
345
		<td class="list">
346
			<table border="0" cellspacing="0" cellpadding="1">
347
				<tr>
348
					<td width="17"></td>
349
					<td valign="middle"><a href="services_dnsmasq_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td>
350
				</tr>
351
			</table>
352
		</td>
353
	</tr>
354
	</tfoot>
355
</table>
356 6661dbcf jim-p
<br/>
357
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont">
358
<tr>
359
	<td colspan="5" valign="top" class="listtopic"><?=gettext("Domain Overrides");?></td>
360
</tr>
361
<tr>
362 70edf50d jim-p
	<tr>
363 6661dbcf jim-p
		<td><p><?=gettext("Entries in this area override an entire domain by specifying an".
364 70edf50d jim-p
		" authoritative DNS server to be queried for that domain.");?></p></td>
365
	</tr>
366 6661dbcf jim-p
</tr>
367 70edf50d jim-p
</table>
368 6661dbcf jim-p
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont sortable">
369 70edf50d jim-p
	<thead>
370
	<tr>
371
		<td width="35%" class="listhdrr"><?=gettext("Domain");?></td>
372
		<td width="20%" class="listhdrr"><?=gettext("IP");?></td>
373
		<td width="35%" class="listhdr"><?=gettext("Description");?></td>
374
		<td width="10%" class="list">
375
			<table border="0" cellspacing="0" cellpadding="1">
376
				<tr>
377
					<td width="17" heigth="17"></td>
378
					<td><a href="services_dnsmasq_domainoverride_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td>
379
				</tr>
380
			</table>
381
		</td>
382
	</tr>
383
	</thead>
384
	<tbody>
385
	<?php $i = 0; foreach ($a_domainOverrides as $doment): ?>
386
	<tr>
387
		<td class="listlr">
388
			<?=strtolower($doment['domain']);?>&nbsp;
389
		</td>
390
		<td class="listr">
391
			<?=$doment['ip'];?>&nbsp;
392
		</td>
393
		<td class="listbg">
394
			<?=htmlspecialchars($doment['descr']);?>&nbsp;
395
		</td>
396
		<td valign="middle" nowrap class="list"> <a href="services_dnsmasq_domainoverride_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a>
397
			&nbsp;<a href="services_dnsmasq.php?act=del&type=doverride&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this domain override?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
398
	</tr>
399
	<?php $i++; endforeach; ?>
400
	</tbody>
401
	<tfoot>
402
	<tr>
403
		<td class="list" colspan="3"></td>
404
		<td class="list">
405
		<table border="0" cellspacing="0" cellpadding="1">
406
			<tr>
407
				<td width="17" heigth="17"></td>
408
				<td><a href="services_dnsmasq_domainoverride_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td>
409
			</tr>
410
		</table>
411
		</td>
412
	</tr>
413
	</tfoot>
414
</table>
415
</form>
416 6a01ea44 Bill Marquette
<script language="JavaScript">
417
<!--
418
enable_change(false);
419
//-->
420
</script>
421 5b237745 Scott Ullrich
<?php include("fend.inc"); ?>
422
</body>
423
</html>