diff options
author | Scott Ullrich <sullrich@gmail.com> | 2011-09-25 17:57:11 -0400 |
---|---|---|
committer | Scott Ullrich <sullrich@gmail.com> | 2011-09-25 17:57:11 -0400 |
commit | a30afe0e594978996ad50e580e46fe87cb21605c (patch) | |
tree | 059fc66488b0cd7d9c4f93fcf51d5bfbc4453da5 /usr/local | |
parent | b2a67b558c40c18a1519cd56cccaabd72e04f69d (diff) | |
download | pfsense-a30afe0e594978996ad50e580e46fe87cb21605c.zip pfsense-a30afe0e594978996ad50e580e46fe87cb21605c.tar.gz |
Add checkbox to invoke full backup prior to upgrade
Diffstat (limited to 'usr/local')
-rwxr-xr-x | usr/local/www/system_firmware_auto.php | 3 | ||||
-rwxr-xr-x | usr/local/www/system_firmware_check.php | 5 |
2 files changed, 8 insertions, 0 deletions
diff --git a/usr/local/www/system_firmware_auto.php b/usr/local/www/system_firmware_auto.php index 2daa6a2..152d7ec 100755 --- a/usr/local/www/system_firmware_auto.php +++ b/usr/local/www/system_firmware_auto.php @@ -53,6 +53,9 @@ if(isset($curcfg['alturl']['enable'])) $updater_url = "{$config['system']['firmware']['alturl']['firmwareurl']}"; else $updater_url = $g['update_url']; + +if($_POST['backupbeforeupgrade']) + touch("/tmp/perform_full_backup.txt"); $pgtitle = array(gettext("Diagnostics"),gettext("Firmware"),gettext("Auto Update")); include("head.inc"); diff --git a/usr/local/www/system_firmware_check.php b/usr/local/www/system_firmware_check.php index c0e9e1d..73e2f85 100755 --- a/usr/local/www/system_firmware_check.php +++ b/usr/local/www/system_firmware_check.php @@ -97,6 +97,9 @@ include("head.inc"); <!-- command output box --> <textarea border='1' bordercolordark='#000000' bordercolorlight='#000000' cols='90' rows='9' name='output' id='output' wrap='hard'> </textarea> + <div id='backupdiv' name='backupdiv' style='visibility:hidden'> + <br/><input type="checkbox" name='backupbeforeupgrade' id='backupbeforeupgrade'> <?=gettext("Perform full backup prior to upgrade");?> + </div> </center> <p> <center><input id='invokeupgrade' style='visibility:hidden' type="submit" value="<?=gettext("Invoke Auto Upgrade"); ?>"> @@ -162,6 +165,8 @@ if ($needs_system_upgrade == false) { } echo "\n<script>$('invokeupgrade').style.visibility = 'visible';</script>"; +echo "\n<script>$('backupdiv').style.visibility = 'visible';</script>"; + $txt = gettext("A new version is now available") . "\\n\\n"; $txt .= gettext("Current version") .": ". $current_installed_version . "\\n"; if ($g['platform'] == "nanobsd") { |