%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ page trimDirectiveWhitespaces="true" %>
<%@ page import="org.crosswire.community.projects.ntmss.data.Apparatus" %>
<%@ page import="org.crosswire.community.RightsAndRoles" %>
<%
int segID = -1; try {segID = Integer.parseInt(request.getParameter("segID"));} catch (Exception e){}
int docID = -1; try {docID = Integer.parseInt(request.getParameter("docID"));} catch (Exception e){}
String hand = request.getParameter("hand"); if (hand == null) hand = "";
int readingID = -1; try {readingID = Integer.parseInt(request.getParameter("readingID"));} catch (Exception e){}
boolean unsure = "true".equals(request.getParameter("unsure"));
String transcription = request.getParameter("transcription"); if (transcription == null) transcription = "";
if (transcription != null) transcription = new String(transcription.getBytes("iso8859-1"), "UTF-8");
String comment = request.getParameter("comment");
if (comment != null) comment = new String(comment.getBytes("iso8859-1"), "UTF-8");
if (docID > -1 && segID > -1) {
response.setContentType("text/xml");
String role = "Live Text Critic";
// let's check to see if we're a privileged user
boolean permission = RightsAndRoles.hasRole(request, response, role);
// ---------------------------------------------
if (true || permission) {
Apparatus.setSegmentReadingWitness(segID, docID, hand, readingID, unsure, transcription, comment);
%>
Submit a new or modified variant reading for a manuscript
| docID | manuscript id for the variant reading, e.g., 10046 |
| segID | segment id for the variant reading, e.g., 10 |
| hand | optional alternatate hand for the variant reading, e.g., 'C' |
| readingID | reading id for this manuscript at this variant segment, e.g., 1003 |
| unsure | if this reading is unsure, e.g., true |
| comment | comment regarding this reading |