if ($show_continue_button) {
//Print the continue button to execute the restore NOW !!!!
//All is prepared !!!
- echo "<center>";
+ echo "<div style='text-align:center'>";
$hidden["launch"] = "execute";
$hidden["file"] = $file;
$hidden["id"] = $id;
}
}
print_single_button("restore.php", $hidden, get_string("restorecoursenow"),"post");
- echo "</center>";
+ echo "</div>";
} else {
//Show error
error ("Something was wrong checking restore preferences");
</script>
<form id="form1" method="post" action="restore.php">
-<table cellpadding="5">
+<div>
+<table cellpadding="5" class="boxaligncenter">
<?php
//First, course destination
}
} else {
//Module isn't restorable
- echo "<input type=\"hidden\" name=\"$restore_var\" value=\"0\" />";
- echo "<input type=\"hidden\" name=\"$user_info_var\" value=\"0\" />";
+ $nonrestmod .= "<input type=\"hidden\" name=\"$restore_var\" value=\"0\" />";
+ $nonrestmod .= "<input type=\"hidden\" name=\"$user_info_var\" value=\"0\" />";
}
} else {
//Module isn't restorable
- echo "<input type=\"hidden\" name=\"$restore_var\" value=\"0\" />";
- echo "<input type=\"hidden\" name=\"$user_info_var\" value=\"0\" />";
+ $nonrestmod .= "<input type=\"hidden\" name=\"$restore_var\" value=\"0\" />";
+ $nonrestmod .= "<input type=\"hidden\" name=\"$user_info_var\" value=\"0\" />";
}
} else {
//Module isn't restorable
- echo "<input type=\"hidden\" name=\"$restore_var\" value=\"0\" />";
- echo "<input type=\"hidden\" name=\"$user_info_var\" value=\"0\" />";
+ $nonrestmod .= "<input type=\"hidden\" name=\"$restore_var\" value=\"0\" />";
+ $nonrestmod .= "<input type=\"hidden\" name=\"$user_info_var\" value=\"0\" />";
}
$currentrow = ($currentrow + 1) % 2;
}
//Line
- echo "<tr><td colspan=\"4\"><hr /></td></tr>";
+ echo "<tr><td colspan=\"4\">$nonrestmod<hr /></td></tr>";
//Now print the Metacourse tr
echo "<tr>";
echo "</td></tr>";
}
?>
-</td></tr></table>
+</table>
<hr/>
<?php
}
echo ('<table width="100%" class="restore-form-instances">');
-echo ('<tr><td align="right"><b>'.get_string('sourcerole').'</b></td><td align="left"><b>'.get_string('targetrole').'</b></td></tr>');
+echo ('<tr><td align="right" style="width:50%"><b>'.get_string('sourcerole').'</b></td><td align="left" style="width:50%"><b>'.get_string('targetrole').'</b></td></tr>');
if ($info->backup_moodle_version < 2006092801) {
// 1.6 and below backup
?>
<br />
-<center>
+<div style="text-align:center">
<input type="hidden" name="id" value="<?php p($id) ?>" />
<input type="hidden" name="launch" value="check" />
<input type="hidden" name="fromform" value="1" />
<input type="submit" value="<?php print_string("continue") ?>" />
<input type="submit" name="cancel" value="<?php print_string("cancel") ?>" />
-</center>
+</div>
+</div>
</form>
if (function_exists($function_name)) {
if (!defined('RESTORE_SILENTLY')) {
echo "<li>".get_string ("from")." ".get_string("modulenameplural",$name);
- echo '</li>';
}
$status = $function_name($restore);
+ if (!defined('RESTORE_SILENTLY')) {
+ echo '</li>';
+ }
}
}
}
//with some hidden fields
if ($status) {
if (!defined('RESTORE_SILENTLY')) {
- echo "<br /><center>";
+ echo "<br /><div style='text-align:center'>";
$hidden["backup_unique_code"] = $backup_unique_code;
$hidden["launch"] = "form";
$hidden["file"] = $file;
$hidden["id"] = $id;
print_single_button("restore.php", $hidden, get_string("continue"),"post");
- echo "</center>";
+ echo "</div>";
}
else {
if (empty($noredirect)) {
} // no need to return false here, it's recoverable.
}
}
+
+ if (!defined('RESTORE_SILENTLY')) {
+ echo "</li>";
+ }
}
//Now create metacourse info
//Only to new courses!
if ($restore->restoreto == 2) {
if (!defined('RESTORE_SILENTLY')) {
- echo "</li><li>".get_string("creatingmetacoursedata");
+ echo "<li>".get_string("creatingmetacoursedata");
}
if (!$status = restore_create_metacourse($restore,$xml_file)) {
if (!defined('RESTORE_SILENTLY')) {
//Now create course files as needed
if ($status and ($restore->course_files)) {
if (!defined('RESTORE_SILENTLY')) {
- echo "<li>".get_string("copyingcoursefiles")."</li>";
+ echo "<li>".get_string("copyingcoursefiles");
}
if (!$status = restore_course_files($restore)) {
if (empty($status)) {
echo "</ul>";
}
}
+ if (!defined('RESTORE_SILENTLY')) {
+ echo "</li>";
+ }
}
//Now create messages as needed