Project

General

Profile

« Previous | Next » 

Revision a2578c27

Added by Anthony Wrather over 13 years ago

Updated DHCP IPv4 and IPv6 to allow global and host based filename and root-path.

View differences:

usr/local/www/services_dhcp_edit.php
87 87
        $pconfig['mac'] = $a_maps[$id]['mac'];
88 88
		$pconfig['hostname'] = $a_maps[$id]['hostname'];
89 89
        $pconfig['ipaddr'] = $a_maps[$id]['ipaddr'];
90
	$pconfig['netbootfile'] = $a_maps[$id]['netbootfile'];
90
	    $pconfig['filename'] = $a_maps[$id]['filename'];
91
		$pconfig['rootpath'] = $a_maps[$id]['rootpath'];
91 92
        $pconfig['descr'] = $a_maps[$id]['descr'];
92 93
} else {
93 94
        $pconfig['mac'] = $_GET['mac'];
94 95
		$pconfig['hostname'] = $_GET['hostname'];
95
	$pconfig['netbootfile'] = $_GET['netbootfile'];
96
	    $pconfig['filename'] = $_GET['filename'];
97
		$pconfig['rootpath'] = $_GET['rootpath'];
96 98
        $pconfig['descr'] = $_GET['descr'];
97 99
}
98 100

  
......
166 168
		$mapent['ipaddr'] = $_POST['ipaddr'];
167 169
		$mapent['hostname'] = $_POST['hostname'];
168 170
		$mapent['descr'] = $_POST['descr'];
169
		$mapent['netbootfile'] = $_POST['netbootfile'];
171
		$mapent['filename'] = $_POST['filename'];
172
		$mapent['rootpath'] = $_POST['rootpath'];
170 173

  
171 174
		if (isset($id) && $a_maps[$id])
172 175
			$a_maps[$id] = $mapent;
......
232 235
                </tr>				
233 236
                <?php if($netboot_enabled) { ?>
234 237
		<tr>
235
		  <td width="22%" valign="top" class="vncell">Netboot filename</td>
238
		  <td width="22%" valign="top" class="vncell">Netboot Filename</td>
236 239
		  <td width="78%" class="vtable">
237
		    <input name="netbootfile" type="text" class="formfld unknown" id="netbootfile" size="20" value="<?=htmlspecialchars($pconfig['netbootfile']);?>">
240
		    <input name="filename" type="text" class="formfld unknown" id="filename" size="20" value="<?=htmlspecialchars($pconfig['filename']);?>">
238 241
		    <br> <span class="vexpl">Name of the file that should be loaded when this host boots off of the network, overrides setting on main page.</span></td>
239 242
		</tr>
243
		<tr>
244
		  <td width="22%" valign="top" class="vncell">Root Path</td>
245
		  <td width="78%" class="vtable">
246
			<input name="rootpath" type="text" class="formfld unknown" id="rootpath" size="90" value="<?=htmlspecialchars($pconfig['rootpath']);?>">
247
		    <br> <span class="vexpl"><?=gettext("Enter the"); ?> <b><?=gettext("root-path"); ?></b>-<?=gettext("string");?>, overrides setting on main page.</span></td>
248
		</tr>
240 249
		<?php } ?>
241 250
                <tr> 
242 251
                  <td width="22%" valign="top" class="vncell"><?=gettext("Description");?></td>

Also available in: Unified diff