include_once $relPath . 'slim_header.inc'; include_once $relPath . 'metarefresh.inc'; include_once 'PPage.inc'; include_once 'proof_frame.inc'; include_once 'text_frame_std.inc'; require_login(); /* $_POST: $projectid, $proj_state, $imagefile, $page_state, $text_data, $button1, $button2, $button3, $button4, ... $button1_x, $button2_x, $button3_x, $button4_x, ... */ $projectid = validate_projectID('projectid', @$_POST['projectid']); $proj_state = $_POST['proj_state']; $imagefile = validate_page_image_filename('imagefile', @$_POST['imagefile']); $text_data = array_get($_POST, 'text_data', ''); define('B_TEMPSAVE', 1); define('B_SAVE_AND_DO_ANOTHER', 2); define('B_QUIT', 3); define('B_SWITCH_LAYOUT', 4); define('B_SAVE_AND_QUIT', 5); define('B_REPORT_BAD_PAGE', 6); define('B_RETURN_PAGE_TO_ROUND', 7); define('B_REVERT_TO_ORIGINAL', 8); define('B_REVERT_TO_LAST_TEMPSAVE', 9); define('B_RUN_SPELL_CHECK', 10); // set tbutton $tbutton = NULL; # default value, will result in error if not overridden below if (isset($_POST['button1']) || isset($_POST['button1_x'])) {
<?php $relPath = "./../../pinc/"; include_once $relPath . 'base.inc'; include_once $relPath . 'stages.inc'; include_once $relPath . 'theme.inc'; include_once $relPath . 'Project.inc'; include_once $relPath . 'links.inc'; include_once $relPath . "DifferenceEngineWrapper.inc"; require_login(); $projectid = validate_projectID('project', @$_GET['project']); $image = validate_page_image_filename('image', @$_GET['image'], true); $L_round_num = get_integer_param($_GET, 'L_round_num', null, 0, MAX_NUM_PAGE_EDITING_ROUNDS); $R_round_num = get_integer_param($_GET, 'R_round_num', null, 0, MAX_NUM_PAGE_EDITING_ROUNDS); $project = new Project($projectid); $state = $project->state; $project_title = $project->nameofwork; $navigation_text = ""; if (!$project->pages_table_exists) { // This shouldn't normally happen -- // if the page table doesn't exist, a "diff" link shouldn't be shown. // But a user might have a bookmarked or otherwise saved a 'diff' URL. echo "<p>", _("Page details are not available for this project."), "</p>\n"; echo "<p>", _("Project ID"), ": {$projectid}</p>\n"; echo "<p>", _("Title"), ":{$project_title}</p>\n"; exit; } // -------------------------------------------------------------- // get information about this diff if ($L_round_num == 0) { $L_text_column_name = 'master_text';
output_header($title, NO_STATSBAR, $extra_args); echo "<br>\n"; echo "<h1>" . $title . "</h1>\n"; echo "<hr>\n"; // Validate the $projectid_ and $from_image_ 'by hand' $projectid_ = array_get($_POST, 'projectid_', NULL); if (is_array($projectid_)) { foreach ($projectid_ as $which => $projectid) { $projectid_[$which] = validate_projectID("projectid_[{$which}]", $projectid); } } $from_image_ = array_get($_POST, 'from_image_', NULL); if (is_array($from_image_)) { foreach ($from_image_ as $which => $filename) { if ($filename) { validate_page_image_filename("from_image_[{$which}]", $filename); } } } $action = get_enumerated_param($_POST, 'action', 'showform', array('showform', 'showagain', 'check', 'docopy')); $page_name_handling = get_enumerated_param($_POST, 'page_name_handling', null, array('PRESERVE_PAGE_NAMES', 'RENUMBER_PAGES'), true); $transfer_notifications = get_integer_param($_POST, 'transfer_notifications', 0, 0, 1); $add_deletion_reason = get_integer_param($_POST, 'add_deletion_reason', 0, 0, 1); $merge_wordcheck_files = get_integer_param($_POST, 'merge_wordcheck_files', 0, 0, 1); $repeat_project = get_enumerated_param($_POST, 'repeat_project', null, array('TO', 'FROM', 'NONE'), true); switch ($action) { case 'showform': display_form($projectid_, $from_image_, $page_name_handling, $transfer_notifications, $add_deletion_reason, $merge_wordcheck_files, $repeat_project, FALSE); break; case 'showagain': display_form($projectid_, $from_image_, $page_name_handling, $transfer_notifications, $add_deletion_reason, $merge_wordcheck_files, $repeat_project, TRUE);
$relPath = "./../../pinc/"; include_once $relPath . 'base.inc'; include_once $relPath . 'Project.inc'; include_once $relPath . 'project_states.inc'; include_once $relPath . 'theme.inc'; include_once $relPath . 'metarefresh.inc'; require_login(); if (!$site_supports_metadata) { echo 'md_phase2.php: $site_supports_metadata is false, so exiting.'; exit; } $projectid = validate_projectID('projectid', @$_GET['projectid']); if (!isset($_GET['imagename'])) { $imagename = null; } else { $imagename = validate_page_image_filename('imagename', @$_GET['imagename']); } // $ppage = get_requested_PPage(); if (!isset($imagename)) { //find next available page for this project $result = mysql_query("SELECT image FROM {$projectid} WHERE state = 'avail_md_second' ORDER BY image ASC LIMIT 1"); //if no more images $numrows = mysql_num_rows($result); if ($numrows == '0') { $body = _("No more files available for proofreading for this round of the project.<br> You will be taken back to the project listing page in 4 seconds."); //////////this will be changed to pre-processing state $result = mysql_query("UPDATE {$projectid} SET state = 'P1.page_avail'"); $result = mysql_query("UPDATE projects SET state = '" . PROJ_P1_AVAILABLE . "' WHERE projectid = '{$projectid}'"); ////////// metarefresh(5, "md_available.php", "Image Metadata Collection", $body); exit;
$relPath = "./../../pinc/"; include_once $relPath . 'base.inc'; include_once $relPath . 'project_states.inc'; include_once $relPath . 'theme.inc'; include_once $relPath . 'DPage.inc'; include_once $relPath . 'Project.inc'; include_once $relPath . 'stages.inc'; include_once $relPath . 'forum_interface.inc'; include_once $relPath . 'project_edit.inc'; include_once $relPath . 'misc.inc'; // attr_safe(), html_safe() include_once 'page_table.inc'; // page_state_is_a_bad_state() require_login(); $projectid = validate_projectID('projectid', @$_REQUEST['projectid']); $image = validate_page_image_filename('image', @$_REQUEST['image']); $modify = array_get($_REQUEST, 'modify', ''); $cancel = array_get($_POST, 'cancel', ''); $prev_text = array_get($_POST, 'prev_text', NULL); $prevtext_column = array_get($_POST, 'prevtext_column', NULL); $resolution = array_get($_POST, 'resolution', NULL); if (user_can_edit_project($projectid) != USER_CAN_EDIT_PROJECT) { die("You are not authorized to manage this project."); } // If the user hit a cancel button, return them to the starting form if ($cancel) { $modify = ''; } if (!$resolution) { //Find out information about the bad page report $result = mysql_query("SELECT * FROM {$projectid} WHERE image='{$image}'");
include_once $relPath . 'theme.inc'; include_once $relPath . 'project_edit.inc'; include_once $relPath . 'Project.inc'; include_once $relPath . 'misc.inc'; // attr_safe() include_once 'page_table.inc'; include_once 'page_operations.inc'; require_login(); $projectid = validate_projectID('projectid', @$_REQUEST['projectid']); $operation = get_enumerated_param($_REQUEST, 'operation', null, array('clear', 'delete')); $selected_pages = @$_REQUEST['selected_pages']; if (!is_array($selected_pages)) { die(_('selected_pages is not a list of pages.')); } foreach ($selected_pages as $image => $setting) { validate_page_image_filename('selected_pages', $image); } output_header(_("Edit Pages Confirmation"), NO_STATSBAR); echo "<br>\n"; $project = new Project($projectid); abort_if_cant_edit_project($projectid); // ----------------------------------------------------------------------------- // Check the set of selected pages. if (count($selected_pages) == 0) { echo _("You did not select any pages.") . "<br>\n"; echo "<br>\n"; exit; } // ----------------------------------------------------------------------------- $page_func_map = array('clear' => 'page_clear', 'delete' => 'page_del'); $page_request_map = array('clear' => _('You requested that each page have the effects of its current round be cleared.'), 'delete' => _('You requested that each page be deleted.'));