diff options
author | Stephen Beaver <sbeaver@netgate.com> | 2015-12-17 08:13:55 -0500 |
---|---|---|
committer | Stephen Beaver <sbeaver@netgate.com> | 2015-12-17 08:13:55 -0500 |
commit | 15281e444fdf5b1133e661ce5f75d589328f7dbc (patch) | |
tree | 9bf0004e28aa6d0517ba6a102f9ee2a9b810b755 /src/usr/local/www/pkg.php | |
parent | 2ef13b6cd37a6d99c1402b25812fc30481e42930 (diff) | |
download | pfsense-15281e444fdf5b1133e661ce5f75d589328f7dbc.zip pfsense-15281e444fdf5b1133e661ce5f75d589328f7dbc.tar.gz |
Save button fix - part deux
Diffstat (limited to 'src/usr/local/www/pkg.php')
-rwxr-xr-x | src/usr/local/www/pkg.php | 44 |
1 files changed, 19 insertions, 25 deletions
diff --git a/src/usr/local/www/pkg.php b/src/usr/local/www/pkg.php index 93b911a..7e4d6b0 100755 --- a/src/usr/local/www/pkg.php +++ b/src/usr/local/www/pkg.php @@ -232,33 +232,27 @@ events.push(function() { ?> }); -<?php -if ($pkg['adddeleteeditpagefields']['movable']) { -?> - function save_changes_to_xml(xml) { - var ids = $('#mainarea table tbody').sortable('serialize', {key:"ids[]"}); - var strloading="<?=gettext('Saving changes...')?>"; - if (confirm("<?=gettext("Do you really want to save changes?")?>")) { - $.ajax({ - type: 'get', - cache: false, - url: "<?=$_SERVER['SCRIPT_NAME']?>", - data: {xml:'<?=$xml?>', act:'update', ids: ids}, - beforeSend: function() { - $('#savemsg').empty().html(strloading); - }, - error: function(data) { - $('#savemsg').empty().html('Error:' + data); - }, - success: function(data) { - $('#savemsg').empty().html(data); - } - }); - } +function save_changes_to_xml(xml) { + var ids = $('#mainarea table tbody').sortable('serialize', {key:"ids[]"}); + var strloading="<?=gettext('Saving changes...')?>"; + if (confirm("<?=gettext("Do you really want to save changes?")?>")) { + $.ajax({ + type: 'get', + cache: false, + url: "<?=$_SERVER['SCRIPT_NAME']?>", + data: {xml:'<?=$xml?>', act:'update', ids: ids}, + beforeSend: function() { + $('#savemsg').empty().html(strloading); + }, + error: function(data) { + $('#savemsg').empty().html('Error:' + data); + }, + success: function(data) { + $('#savemsg').empty().html(data); + } + }); } -<?php } -?> //]]> </script> |