diff options
Diffstat (limited to 'usr/local/www/services_dhcp_edit.php')
-rw-r--r-- | usr/local/www/services_dhcp_edit.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/usr/local/www/services_dhcp_edit.php b/usr/local/www/services_dhcp_edit.php index 3213db5..bbc52ca 100644 --- a/usr/local/www/services_dhcp_edit.php +++ b/usr/local/www/services_dhcp_edit.php @@ -59,6 +59,8 @@ if(!$g['services_dhcp_server_enable']) { require("guiconfig.inc"); +$referer = (isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '/services_dhcp.php'); + $if = $_GET['if']; if ($_POST['if']) $if = $_POST['if']; @@ -531,7 +533,8 @@ include("head.inc"); <tr> <td width="22%" valign="top"> </td> <td width="78%"> - <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save");?>" /> <input class="formbtn" type="button" value="<?=gettext("Cancel");?>" onclick="history.back()" /> + <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save");?>" /> + <input type="button" class="formbtn" value="<?=gettext("Cancel");?>" onclick="window.location.href='<?=$referer;?>'" /> <?php if (isset($id) && $a_maps[$id]): ?> <input name="id" type="hidden" value="<?=htmlspecialchars($id);?>" /> <?php endif; ?> |