[LON-CAPA-cvs] cvs: loncom /html/adm/help ext_examples.html ext_examples.html.meta ext_examples.library ext_examples.library.meta ext_examples.problem ext_examples.problem.meta

www lon-capa-cvs@mail.lon-capa.org
Wed, 09 Jun 2004 13:55:42 -0000


This is a MIME encoded message

--www1086789342
Content-Type: text/plain

www		Wed Jun  9 09:55:42 2004 EDT

  Added files:                 
    /loncom/html/adm/help	ext_examples.html ext_examples.html.meta 
                         	ext_examples.library 
                         	ext_examples.library.meta 
                         	ext_examples.problem 
                         	ext_examples.problem.meta 
  Log:
  These are useful and should become part of the distribution.
  
  
--www1086789342
Content-Type: text/plain
Content-Disposition: attachment; filename="www-20040609095542.txt"


Index: loncom/html/adm/help/ext_examples.html
+++ loncom/html/adm/help/ext_examples.html
<html>
<body>
<import id="11">ext_examples.library</import>
</body>
</html>

Index: loncom/html/adm/help/ext_examples.html.meta
+++ loncom/html/adm/help/ext_examples.html.meta

<abstract></abstract>
<author>Guy D Albertelli II</author>
<copyright>public</copyright>
<creationdate>1084285297</creationdate>
<customdistributionfile></customdistributionfile>
<dependencies></dependencies>
<import part="" id="11">ext_examples.library</import>
<keywords>lon,capa EXT &amp;EXT internals</keywords>
<language>seniso</language>
<lastrevisiondate>1084285297</lastrevisiondate>
<mime>html</mime>
<notes></notes>
<obsolete></obsolete>
<obsoletereplacement></obsoletereplacement>
<owner>albertel@msu</owner>
<subject>Lon-CAPA Documentation</subject>
<title>Example HTML page using &amp;EXT()</title>
Index: loncom/html/adm/help/ext_examples.library
+++ loncom/html/adm/help/ext_examples.library
<library>
<startoutext />
Some things to do with &amp;EXT()<br />
<table border="1">
<tr><th>Incantation</th><th>result</th><th>Explanation</th></tr>
<tr><td>request.filename</td><td>&EXT('request.filename')</td>
    <td>full internal path of the current resource</td></tr>
<tr><td>request.uri</td><td>&EXT('request.uri')</td>
    <td>Uri of the currently viewed resource</td></tr>
<tr><td>request.state</td><td>&EXT('request.state')</td>
    <td>state of the resource, eith construct or publish</td></tr>
<tr><td>user.name</td><td>&EXT('user.name')</td>
    <td>username of user</td></tr>
<tr><td>user.domain</td><td>&EXT('user.domain')</td>
    <td>Domain the user is in</td></tr>
<tr><td>user.course.sec</td><td>&EXT('user.course.sec')</td>
    <td>Users's Course Section</td></tr>
<tr><td>environment.firstname</td><td>&EXT('environment.firstname')</td>
    <td>User's firstname</td></tr>
<tr><td>environment.middlename</td><td>&EXT('environment.middlename')</td>
    <td>User's middle name</td></tr>
<tr><td>environment.lastname</td><td>&EXT('environment.lastname')</td>
    <td>User's lastname</td></tr>
<tr><td>environment.generation</td><td>&EXT('environment.generation')</td>
    <td>Jr., Sr., III, etc.</td></tr>
<tr><td>environment.screenname</td><td>&EXT('environment.screenname')</td>
    <td>User screen name (name that appears in FDBK postings)</td></tr>
<tr><td>environment.nickname</td><td>&EXT('environment.nickname')</td>
    <td>User nick name. (Name the user prefers to be called in person</td></tr>
<tr><td>environment.id</td><td>&EXT('environment.id')</td>
    <td>user id number</td></tr>
<tr><td>request.browser.version</td><td>&EXT('request.browser.version')</td>
    <td>Version of the users Browser</td></tr>
<tr><td>request.browser.type</td><td>&EXT('request.browser.type')</td>
    <td>What type of browser is the user using</td></tr>
<tr><td>course.description</td><td>&EXT('course.decription')</td>
    <td>Decriptive name for a course</td></tr>
<tr><td>course.num</td><td>&EXT('course.num')</td>
    <td>Internal Course Identifier</td></tr>
<tr><td>course.url</td><td>&EXT('course.url')</td>
    <td>Current course toplevel map.</td></tr>
<tr><td>query.*</td><td></td>
    <td>query.* allows access to the passed in form parameters</td></tr>
<tr><td>query.grade_target</td><td>&EXT('query.grade_target')</td>
    <td>Ignore this. It isn't generally useful.</td></tr>
</table>
Other things:
<table border="1">
<tr><th>Incantation</th><th>result</th><th>Explanation</th></tr>
<tr><td>&#36;external::target</td>
    <td><display>$external::target</display></td>
    <td>Whether we are printing (tex) or viewing on screen (web)</td></tr>
<tr><td>&#36;external::part</td>
    <td><display>$external::part</display></td>
    <td>current Part id </td></tr>
<tr><td>&#36;external::gradestatus</td>
    <td><display>$external::gradestatus</display></td>
    <td>The solved status of the current part.</td></tr>
<tr><td>&#36;external::datestatus</td>
    <td><tex>\verb+</tex><display>$external::datestatus</display><tex>+</tex></td>
    <td>The current status of the problem (CLOSE, CAN_ANSWER, etc.)</td></tr>
<tr><td>&#36;external::randomseed</td>
    <td><display>$external::randomseed</display></td>
    <td>The randomseed currently in use.</td></tr>
<tr><td></td><td></td>
    <td></td></tr>
</table>
<endouttext />
</library>

Index: loncom/html/adm/help/ext_examples.library.meta
+++ loncom/html/adm/help/ext_examples.library.meta

<abstract></abstract>
<author>Guy D Albertelli II</author>
<copyright>public</copyright>
<creationdate>1084284979</creationdate>
<customdistributionfile></customdistributionfile>
<dependencies></dependencies>
<keywords>lon,capa EXT &amp;EXT internals</keywords>
<language>seniso</language>
<lastrevisiondate>1084284979</lastrevisiondate>
<mime>library</mime>
<notes></notes>
<obsolete></obsolete>
<obsoletereplacement></obsoletereplacement>
<owner>albertel@msu</owner>
<subject>Lon-CAPA Documentation</subject>
<title>Library of Examples of what can be done with &amp;EXT()</title>
Index: loncom/html/adm/help/ext_examples.problem
+++ loncom/html/adm/help/ext_examples.problem
<problem>
<import id="11">ext_examples.library</import>
<startouttext />
<hr />
Some things to do with &amp;EXT() inside of a homework problem.<br />
Anything data that shows up in the 'all deatils' view in PGRD is avaliable, as is the current value of any 
<table border="1">
<tr><th>Incantation</th><th>result</th><th>Explanation</th></tr>
<tr><td>user.resource.resource.&lt;partid&gt;.&lt;responseid&gt;.submission</td><td>&EXT('user.resource.resource.0.12.submission')</td>
    <td>text of the most recent submission</td></tr>
<tr><td>user.resource.resource.&lt;partid&gt;.&lt;responseid&gt;.awarddetail</td><td>&EXT('user.resource.resource.0.12.awarddetail')</td>
    <td>Detail of how the most recent submission was graded. </td></tr>
<tr><td>user.resource.1:resource.&lt;partid&gt;.&lt;responseid&gt;.submission</td><td>&EXT('user.resource.1:resource.0.12.submission')</td>
    <td>text of the submission on the first submission to the problem. The '1:' is not neccessarily the first try on the problem, rather it referes to the first 'transaction' in the data for this problem. Take a look at PGRD for a problem with the submissions view set to 'all details'.</td></tr>

<tr><td>user.resource.resource.&lt;partid&gt;.tries</td><td>&EXT('user.resource.resource.0.tries')</td>
    <td>current number of tries on the problem</td></tr>
<tr><td>user.resource.resource.&lt;partid&gt;.solved</td><td>&EXT('user.resource.resource.0.solved')</td>
    <td>current status of the problem</td></tr>
<tr><td>user.resource.resource.&lt;partid&gt;.awarded</td><td>&EXT('user.resource.resource.0.awarded')</td>
    <td>A floating point number between 0 and 1 inclusive, that is the percentage  of the weight for this problem.</td></tr>
<tr><td>user.resource.resource.&lt;partid&gt;.award</td><td>&EXT('user.resource.resource.0.award')</td>
    <td>Detailed award of the most recent part was graded. (This will be one of the &lt;responseid&gt;'s <tt>awarddetail</tt></td></tr>
</table>
<hr />
You can get access to the current values of some parameters. But these only work reliably in a published problem that is in a course. <br />
<table border="1">
<tr><th>Incantation</th><th>result</th><th>Explanation</th></tr>
<tr><td>resource.&lt;partid&gt;.&lt;responseid&gt;.tolerance</td><td>&EXT('resource.0.12.tolerance')</td>
    <td>Current setting of the tolerance parameter for the particular response.</td></tr>
<tr><td>resource.&lt;partid&gt;.maxtries</td><td>&EXT('resource.0.maxtries')</td>
    <td>Current setting for the maximum number of tries for the part.</td></tr>

</table>
<hr /><endouttext />
<startouttext />
<br />The answer is 1<br />
<endouttext />
<numericalresponse id="12" answer="1">
    <responseparam description="Numerical Tolerance" default="5%" type="tolerance" name="tol" />
  <textline />
</numericalresponse>
</problem>

Index: loncom/html/adm/help/ext_examples.problem.meta
+++ loncom/html/adm/help/ext_examples.problem.meta

<abstract></abstract>
<author>Guy D Albertelli II</author>
<copyright>public</copyright>
<creationdate>1084285143</creationdate>
<customdistributionfile></customdistributionfile>
<dependencies></dependencies>
<import part="0" id="11">ext_examples.library</import>
<keywords>EXT,amp,capa,internals,lon</keywords>
<language>seniso</language>
<lastrevisiondate>1084286220</lastrevisiondate>
<mime>problem</mime>
<notes></notes>
<obsolete></obsolete>
<obsoletereplacement></obsoletereplacement>
<owner>albertel@msu</owner>
<parameter part="0" id="12" name="tol" type="tolerance" default="5%" display="Numerical Tolerance [Part: 0_12]"></parameter>
<parameter part="0" id="12" package="numericalresponse"></parameter>
<parameter part="0" package="part"></parameter>
<partorder></partorder>
<stores part="0" name="awarded" type="float" display="Partial Credit Factor [Part: 0]"></stores>
<stores part="0" name="solved" type="string" display="Problem Status [Part: 0]"></stores>
<stores part="0" name="tries" type="int_zeropos" display="Number of Attempts [Part: 0]"></stores>
<subject>Lon-CAPA Documentation</subject>
<title>Example problem that uses &amp;EXT() to expose what data is available to authors</title>
--www1086789342--