awake.php
5 years ago
cancelBackup.php
5 years ago
cancelDownload.php
5 years ago
checkBackupCreation.php
5 years ago
checkPHPVersionCompatibility.php
5 years ago
checkRestoreCreation.php
5 years ago
cloudDropbox.php
5 years ago
curlChecker.php
5 years ago
deleteBackup.php
5 years ago
dismissDiscountNotice.php
5 years ago
downloadBackup.php
5 years ago
getAction.php
5 years ago
getBackupContent.php
5 years ago
getRunningActions.php
5 years ago
hideNotice.php
5 years ago
importBackup.php
5 years ago
isFeatureAvailable.php
5 years ago
manualBackup.php
5 years ago
modalImport.php
5 years ago
modalManualBackup.php
5 years ago
modalManualRestore.php
5 years ago
modalPrivacy.php
5 years ago
modalReview.php
5 years ago
modalTerms.php
5 years ago
resetStatus.php
5 years ago
restore.php
5 years ago
reviewBannerActions.php
5 years ago
schedule.php
5 years ago
setReviewPopupState.php
5 years ago
setUserInfoVerificationPopupState.php
5 years ago
settings.php
5 years ago
storeSubscriberInfo.php
5 years ago
storeSurveyResult.php
5 years ago
modalManualRestore.php
75 lines
| 1 | <?php |
| 2 | require_once(dirname(__FILE__).'/../boot.php'); |
| 3 | require_once(SG_LIB_PATH.'SGArchive.php'); |
| 4 | $backupName = $_GET['param']; |
| 5 | $backupName = backupGuardRemoveSlashes($backupName); |
| 6 | $backupPath = SG_BACKUP_DIRECTORY.$backupName; |
| 7 | $backupPath= $backupPath.'/'.$backupName.'.sgbp'; |
| 8 | |
| 9 | $archive = new SGArchive($backupPath,'r'); |
| 10 | $headers = $archive->getArchiveHeaders(); |
| 11 | if($headers["selectivRestoreable"]){ |
| 12 | ?> |
| 13 | <div class="modal-dialog"> |
| 14 | <div class="modal-content"> |
| 15 | <div class="modal-header"> |
| 16 | <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> |
| 17 | <h4 class="modal-title"><?php _backupGuardT("Manual Restore") ?></h4> |
| 18 | </div> |
| 19 | <form class="form-horizontal" method="post" id="manualBackup"> |
| 20 | <div class="modal-body sg-modal-body"> |
| 21 | <!-- Multiple Radios --> |
| 22 | <div class="form-group"> |
| 23 | <div class="col-md-12"> |
| 24 | <div class="radio"> |
| 25 | <label for="fullrestore-radio"> |
| 26 | <input type="radio" name="restoreType" id="fullrestore-radio" value="<?php echo SG_RESTORE_MODE_FULL ?>" checked="checked"> |
| 27 | <?php _backupGuardT('Full restore'); ?> |
| 28 | </label> |
| 29 | </div> |
| 30 | <div class="radio"> |
| 31 | <label for="filerestore-radio"> |
| 32 | <input type="radio" name="restoreType" id="filerestore-radio" value="<?php echo SG_RESTORE_MODE_FILES ?>"> |
| 33 | <?php _backupGuardT('Restore files'); ?> |
| 34 | </label> |
| 35 | </div> |
| 36 | <?php if (SGBoot::isFeatureAvailable('SLECTIVE_RESTORE')): ?> |
| 37 | <?php backupGuardGetFileSelectiveRestore(); ?> |
| 38 | <?php endif; ?> |
| 39 | <div class="radio"> |
| 40 | <label for="dbrestore-radio"> |
| 41 | <input type="radio" name="restoreType" id="dbrestore-radio" value="<?php echo SG_RESTORE_MODE_DB ?>"> |
| 42 | <?php _backupGuardT('Restore DB'); ?> |
| 43 | </label> |
| 44 | </div> |
| 45 | |
| 46 | </div> |
| 47 | </div> |
| 48 | </div> |
| 49 | <div class="modal-footer"> |
| 50 | <span class="modal-close-button" data-dismiss="modal">Close</span> |
| 51 | <button type="button" onclick="sgBackup.startRestore('<?php echo addslashes(htmlspecialchars($backupName)) ?>')" class="btn btn-success"><?php _backupGuardT('Restore')?></button> |
| 52 | </div> |
| 53 | </form> |
| 54 | </div> |
| 55 | </div> |
| 56 | <?php |
| 57 | }else{ |
| 58 | ?> |
| 59 | <div class="modal-dialog"> |
| 60 | <div class="modal-content"> |
| 61 | <div class="modal-header"> |
| 62 | <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> |
| 63 | <h4 class="modal-title"><?php _backupGuardT("Are you sure?") ?></h4> |
| 64 | </div> |
| 65 | <div class="modal-footer"> |
| 66 | <button type="button" class="btn btn-default" data-dismiss="modal">Close</button> |
| 67 | <button type="button" onclick="sgBackup.startRestore('<?php echo htmlspecialchars($backupName) ?>')" class="btn btn-primary"><?php _backupGuardT('Restore')?></button> |
| 68 | </div> |
| 69 | </div> |
| 70 | </div> |
| 71 | <?php |
| 72 | } |
| 73 | |
| 74 | |
| 75 |