From: stronk7 Date: Thu, 12 Jun 2003 17:41:52 +0000 (+0000) Subject: Modified to flush data to browser... X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=59728e8d4a615994f50f338615a0c9d4b45c9702;p=moodle.git Modified to flush data to browser... --- diff --git a/backup/mod/assignment/restorelib.php b/backup/mod/assignment/restorelib.php index 2c21ebcd52..14d82d5d49 100644 --- a/backup/mod/assignment/restorelib.php +++ b/backup/mod/assignment/restorelib.php @@ -55,6 +55,11 @@ //The structure is equal to the db, so insert the assignment $newid = insert_record ("assignment",$assignment); + + //Do some output + echo ""; } else { $status = false; @@ -122,6 +130,16 @@ //The structure is equal to the db, so insert the assignment_submission $newid = insert_record ("assignment_submissions",$submission); + + //Do some output + if ($newid % 50 == 0) { + echo "."; + if ($newid % 1000 == 0) { + echo "
"; + } + backup_flush(300); + } + if ($newid) { //We have the newid, update backup_ids backup_putid($restore->backup_unique_code,"assignment_submission",$oldid, diff --git a/backup/mod/choice/restorelib.php b/backup/mod/choice/restorelib.php index 736bfb5700..b49492c1f4 100644 --- a/backup/mod/choice/restorelib.php +++ b/backup/mod/choice/restorelib.php @@ -57,6 +57,11 @@ //The structure is equal to the db, so insert the choice $newid = insert_record ("choice",$choice); + + //Do some output + echo ""; + } else { $status = false; } @@ -112,6 +120,16 @@ //The structure is equal to the db, so insert the choice_answers $newid = insert_record ("choice_answers",$answer); + + //Do some output + if ($newid % 50 == 0) { + echo "."; + if ($newid % 1000 == 0) { + echo "
"; + } + backup_flush(300); + } + if ($newid) { //We have the newid, update backup_ids backup_putid($restore->backup_unique_code,"choice_answers",$oldid, diff --git a/backup/mod/resource/restorelib.php b/backup/mod/resource/restorelib.php index fc1300e37c..37779e356b 100644 --- a/backup/mod/resource/restorelib.php +++ b/backup/mod/resource/restorelib.php @@ -35,7 +35,7 @@ //traverse_xmlize($info); //Debug //print_object ($GLOBALS['traverse_array']); //Debug //$GLOBALS['traverse_array']=""; //Debug - + //Now, build the RESOURCE record structure $resource->course = $restore->course_id; $resource->name = backup_todb($info['MOD']['#']['NAME']['0']['#']); @@ -47,6 +47,11 @@ //The structure is equal to the db, so insert the resource $newid = insert_record ("resource",$resource); + + //Do some output + echo ""; + } else { $status = false; } diff --git a/backup/mod/survey/restorelib.php b/backup/mod/survey/restorelib.php index 2f94cabbc9..8f5a547fee 100644 --- a/backup/mod/survey/restorelib.php +++ b/backup/mod/survey/restorelib.php @@ -54,6 +54,11 @@ //The structure is equal to the db, so insert the survey $newid = insert_record ("survey",$survey); + + //Do some output + echo ""; + } else { $status = false; } @@ -115,6 +123,16 @@ //The structure is equal to the db, so insert the survey_answers $newid = insert_record ("survey_answers",$answer); + + //Do some output + if ($newid % 50 == 0) { + echo "."; + if ($newid % 1000 == 0) { + echo "
"; + } + backup_flush(300); + } + if ($newid) { //We have the newid, update backup_ids backup_putid($restore->backup_unique_code,"survey_answers",$oldid, @@ -161,6 +179,16 @@ //The structure is equal to the db, so insert the survey_analysis $newid = insert_record ("survey_analysis",$analys); + + //Do some output + if ($newid % 50 == 0) { + echo "."; + if ($newid % 1000 == 0) { + echo "
"; + } + backup_flush(300); + } + if ($newid) { //We have the newid, update backup_ids backup_putid($restore->backup_unique_code,"survey_analysis",$oldid,