Projet

Général

Profil

« Précédent | Suivant » 

Révision 62424bdb

Ajouté par Renato Botelho il y a plus de 9 ans

Remove almost all calls to history.back() and make Cancel button back to HTTP_REFERER, there are a couple of places I didn't touch on this commit because it requires more work

Voir les différences:

usr/local/www/firewall_nat_edit.php
44 44
require_once("filter.inc");
45 45
require("shaper.inc");
46 46

  
47
$referer = (isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '/firewall_nat.php');
48

  
47 49
$specialsrcdst = explode(" ", "any (self) pptp pppoe l2tp openvpn");
48 50
$ifdisp = get_configured_interface_with_descr();
49 51
foreach ($ifdisp as $kif => $kdescr) {
......
889 891
                <tr>
890 892
                  <td width="22%" valign="top">&nbsp;</td>
891 893
                  <td width="78%">
892
                    <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>" /> <input type="button" class="formbtn" value="<?=gettext("Cancel"); ?>" onclick="history.back()" />
894
                    <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>" />
895
                    <input type="button" class="formbtn" value="<?=gettext("Cancel");?>" onclick="window.location.href='<?=$referer;?>'" />
893 896
                    <?php if (isset($id) && $a_nat[$id]): ?>
894 897
                    <input name="id" type="hidden" value="<?=htmlspecialchars($id);?>" />
895 898
                    <?php endif; ?>

Formats disponibles : Unified diff