Services\Synchronize::restore PHP Méthode

restore() public méthode

Restore the database and modules from the restore file
public restore ( string $restore_file )
$restore_file string "The location of teh restore zip file"
    public function restore($restore_file)
    {
        @ini_set('max_execution_time', 300);
        // Temporarily increase maximum execution time
        $this->Unzip($restore_file, restore_path());
        $restore_dir = restore_path() . '/backup';
        // $this->dropTables();
        $this->restoreDB($restore_dir);
        $this->restoreModules($restore_dir);
        $this->restorePublic($restore_dir);
    }

Usage Example

 public function postRestore()
 {
     Sentry::logout();
     $synchronizer = new Synchronize($this);
     $restore_file = $synchronizer->copyToRestore(Input::all());
     $synchronizer->restore($restore_file);
     return Redirect::to('/');
 }
All Usage Examples Of Services\Synchronize::restore