Annotation of loncom/html/adm/help/tex/Authoring_ExternalResponse.tex, revision 1.3
1.1 bowersj2 1: \label{Authoring_ExternalResponse}
2:
3:
4: \textbf{externalresponse} is an advanced type of response tag that
5: implements the ability to have an external program grade a response.
6: It expects either a \textbf{textline} or \textbf{textfield} inside
7: the tag. Possible attributes are:
8:
9: \begin{itemize}
1.2 vandui11 10: \item \textbf{url}\index{url}: url to submit the answer form to. It does
1.1 bowersj2 11: not need to be a LON-CAPA machine.
1.3 ! albertel 12: \item \textbf{answer}\index{answer}: data to post in the form element
! 13: \texttt{LONCAPA\_correct\_answer} to the remote site.
1.2 vandui11 14: \item \textbf{form}\index{form}: hash variable name that will be submitted
1.1 bowersj2 15: to the remote site as a HTTP form.
16: \end{itemize}
1.3 ! albertel 17:
! 18: The form sent will consist of
! 19: \begin{itemize}
! 20: \item \textbf{LONCAPA\_student\_response} full text of
! 21: what the student entered in the entry field
! 22: \item \textbf{LONCAPA\_correct\_answer} contents of the answer
! 23: attribute
! 24: \item \textbf{LONCAPA\_language} specified language encoding
! 25: of the requesting resource
! 26: \item \textbf{all items in the form attribute} if any of these clash with the
! 27: above, the above values will overwite the value in the form attribute
! 28: \end{itemize}
! 29:
1.1 bowersj2 30: The response of the remote server needs to be in XML as follows:
31:
32: \begin{itemize}
33: \item \textbf{loncapagrade}\index{loncapagrade}: takes no attributes, but
34: must surround the response.
1.3 ! albertel 35: \item \textbf{awarddetail}\index{awarddetail}: required. The delimited text
1.1 bowersj2 36: inside must be one of the detailed results that appears in the data
37: storage documentation. CVS:loncapa/doc/homework/datastorage, look
38: for \textbf{resource.partid.responseid.awarddetail}.
39: \item \textbf{message}\index{message}: optional message to have shown to
1.2 vandui11 40: the student.
1.1 bowersj2 41: \end{itemize}
42: Example: \begin{verbatim} <loncapagrade>
1.3 ! albertel 43: <awarddetail>INCORRECT</awarddetail>
1.1 bowersj2 44: <message>
45: A message to be shown to the students
46: </message>
47: </loncapagrade>
48: \end{verbatim}
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>