Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Added the backup_flush function use to send some data to the browser

flushing output inmediately
  • Loading branch information...
commit 60b420af996bc3baab7f48f70a29293f77207a4c 1 parent d2c94f4
stronk7 authored
Showing with 12 additions and 0 deletions.
  1. +12 −0 backup/lib.php
View
12 backup/lib.php
@@ -365,6 +365,18 @@ function backup_required_functions() {
}
}
+
+ //This function send n white characters to the browser and flush the
+ //output buffer. Used to avoid browser timeouts and to show the progress.
+ function backup_flush($n=0,$time=false) {
+ if ($time) {
+ $ti = strftime("%X",time());
+ } else {
+ $ti = "";
+ }
+ echo str_repeat(" ", $n) . $ti . "\n";
+ flush();
+ }
?>
Please sign in to comment.
Something went wrong with that request. Please try again.