if ($bitwise & SYNCH_RESTORE_MERGED_BACKUP_TO_REMOTE_HOST) { $restoredMergedBackupToRemoteHost = $SynchManager->restoreMergedBackupToRemoteHost($page->id, $files, $page->session); } /* * Clean up afterwards. Remove the backup files that have been created. */ $SynchManager->clearSessionBackups($page->session); /* * Restore max execution time to its original value */ set_time_limit($originalMaxExecutionTime); // We don't have merging working so assume the synching worked and set the completed flag in the session $page->session->finished = true; } // Save the session synch_Session_controller::saveSession($session); // If we're on a secure page ensure all urls are secure to prevent browser error $securewwwroot = synch_get_http_prefix(); $featuretitle = get_string('synchronise', 'synch'); if ($page->session->finished) { $pagetitle = get_string('session_finish', 'synch'); } else { $pagetitle = get_string('session_start', 'synch'); } // Create the navigation menu $nav = '<a href="' . $securewwwroot . '/synch/">' . get_string('synchronise', 'synch') . '</a> -> ' . $pagetitle; /// Print header. $navlinks = array(); $navlinks[] = array('name' => $featuretitle, 'link' => 'index.php', 'type' => 'activity'); $navlinks[] = array('name' => format_string($pagetitle), 'link' => 'session_start.php?id=' . $page->id, 'type' => 'activityinstance'); $navigation = build_navigation($navlinks);