Skip to content

Commit

Permalink
Edit and rearrange test files for embedded WWproblems. They are all i…
Browse files Browse the repository at this point in the history
…n webwork2/clients/t
  • Loading branch information
mgage committed Jul 28, 2019
1 parent b3117c0 commit 55443f6
Show file tree
Hide file tree
Showing 7 changed files with 158 additions and 341 deletions.
327 changes: 0 additions & 327 deletions clients/t/Second_semester_calculus_topics2.html

This file was deleted.

File renamed without changes.
106 changes: 106 additions & 0 deletions clients/t/test_formats_WWproblems.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<title>test formats for embedded problems</title>
<meta name="generator" content="BBEdit 12.6" />
</head>
<body>

<p>Format: sticky </p>
<p><iframe width="800" height="400"
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0&
&sourceFilePath=Library/ma122DB/set12/s5_4_14.pg&
&problemSeed=123567&
&courseID=daemon_course&
&userID=daemon&
&course_password=daemon&
&showSummary=1&
&displayMode=MathJax&
&problemIdentifierPrefix=102&
&language=en&
&outputformat=sticky"><br/>
</iframe></p>
<p>Format: standard (has error section -- but there should be no errors) </p>
<p><iframe width="800" height="400"
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0&
&sourceFilePath=Library/ma122DB/set12/s5_4_14.pg&
&problemSeed=123567&
&courseID=daemon_course&
&userID=daemon&
&course_password=daemon&
&showSummary=1&
&displayMode=MathJax&
&problemIdentifierPrefix=102&
&language=en&
&outputformat=standard"><br/>
</iframe></p>

<p>Format: simple </p>
<p><iframe width="800" height="400"
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0&
&sourceFilePath=Library/ma122DB/set12/s5_4_14.pg&
&problemSeed=123567&
&courseID=daemon_course&
&userID=daemon&
&course_password=daemon&
&showSummary=1&
&displayMode=MathJax&
&problemIdentifierPrefix=102&
&language=en&
&outputformat=simple"><br/>
</iframe></p>

<p>Format: body_text </p>
<p><iframe width="800" height="400"
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0&
&sourceFilePath=Library/ma122DB/set12/s5_4_14.pg&
&problemSeed=123567&
&courseID=daemon_course&
&userID=daemon&
&course_password=daemon&
&showSummary=1&
&displayMode=MathJax&
&problemIdentifierPrefix=102&
&language=en&
&outputformat=body_text"><br/>
</iframe></p>

<p>Format: PTX </p>
<p><iframe width="800" height="400"
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0&
&sourceFilePath=Library/ma122DB/set12/s5_4_14.pg&
&problemSeed=123567&
&courseID=daemon_course&
&userID=daemon&
&course_password=daemon&
&showSummary=1&
&displayMode=MathJax&
&problemIdentifierPrefix=102&
&language=en&
&outputformat=ptx"><br/>
</iframe></p>

<p>Format: JSON </p>
<p><iframe width="800" height="400"
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0&
&sourceFilePath=Library/ma122DB/set12/s5_4_14.pg&
&problemSeed=123567&
&courseID=daemon_course&
&userID=daemon&
&course_password=daemon&
&showSummary=1&
&displayMode=MathJax&
&problemIdentifierPrefix=102&
&language=en&
&outputformat=json"><br/>
</iframe></p>

</body>
</html>
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ <h2>Problem 1-- xmlrpc version of a simple template</h2>
</p>
<hr>
<iframe width="1000" height="400"
src="http://localhost/webwork2/html2xml?
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0
&sourceFilePath=Library/Utah/Quantitative_Analysis/set4_Derivatives/pr_15.pg
&problemSeed=123567
Expand All @@ -57,7 +57,7 @@ <h2>Problem 2 -- webwork2 version of a simple template</h2>
</p>
<hr>
<iframe width="1000" height="400"
src="http://localhost/webwork2/gage_course/test6/3/?&templateName=simple">
src="https://demo.webwork.rochester.edu/webwork2/gage_course/test6/3/?&templateName=simple">
</iframe>
<hr>
</body>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,19 @@
</style>
</head>
<body>

<iframe width="600" height="600"
src="http://127.0.0.1/webwork2/html2xml?
&answersSubmitted=0
&sourceFilePath=Library/Rochester/setAlgebra01RealNumbers/lhp1_31-34_mo.pg
&problemSeed=123567890
&displayMode=MathJax
&courseID=daemon_course
&userID=daemon
&course_password=daemon
&outputformat=sticky">
</iframe>

<h1>Embedded WeBWorK Problems</h1>
<p>
Problem 1 -- interval notation
Expand All @@ -38,7 +51,7 @@ <h1>Embedded WeBWorK Problems</h1>
</div>
<div class="wwproblem" style="display: none;">
<hr>
<iframe width="600" height=600"
<iframe width="600" height="600"
src="http://localhost/webwork2/html2xml?
&answersSubmitted=0
&sourceFilePath=Library/Rochester/setAlgebra01RealNumbers/lhp1_31-34_mo.pg
Expand All @@ -59,7 +72,7 @@ <h1>Embedded WeBWorK Problems</h1>
</div>
<div class="wwproblem" style="display: none;">
<hr>
<iframe width="800" height=600"
<iframe width="800" height="600"
src="http://localhost/webwork2/html2xml?
&answersSubmitted=0
&sourceFilePath=Library/FortLewis/Calc1/06-01-Antiderivatives-graphically/AF2/AF2.pg
Expand All @@ -82,7 +95,7 @@ <h1>Embedded WeBWorK Problems</h1>
<div class="wwproblem" style="display: none;">
<hr>
<iframe width="800" height="600"
src="http://localhost/webwork2/html2xml?
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0
&problemSeed=123567890
&displayMode=MathJax
Expand All @@ -103,8 +116,8 @@ <h1>Embedded WeBWorK Problems</h1>
</div>
<div class="wwproblem" style="display: none;">
<hr>
<iframe width="800" height=600"
src="http://localhost/webwork2/html2xml?
<iframe width="800" height="600"
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0
&sourceFilePath=MathObjectsLabs2/lab-problem.pg
&problemSeed=123567890
Expand All @@ -128,7 +141,7 @@ <h1>Embedded WeBWorK Problems</h1>
<div class="wwproblem" style="display: none;">
<hr>
<iframe width="800" height="600"
src="http://localhost/webwork2/html2xml?
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0
&sourceFilePath=Library/Rochester/setAlgebra01RealNumbers/lhp1_31-34_mo.pg
&problemSeed=123567890
Expand Down Expand Up @@ -166,8 +179,24 @@ <h1>Embedded WeBWorK Problems</h1>
&outputformat=simple">
</iframe>
<hr></div>


<hr>
<div class="clickme">
Click here to toggle problem display: (PGinfo example)
</div>
<div class="wwproblem" style="display: none;">
<hr>
<iframe width="800" height="600"
src="http://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0&
&sourceFilePath=settesting/pgInfo.pg&
&problemSeed=123567890&
&problemIdentifierPrefix=5555&
&displayMode=MathJax&
&courseID=daemon_course&
&userID=daemon&
&course_password=daemon&
&outputformat=simple">
</iframe>
</body>
</html>

Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ <h2>Problem 1</h2>

<hr>
<iframe width="800" height="600"
src="http://127.0.0.1/webwork2/html2xml?
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0
&sourceFilePath=setDemo/limits.pg
&problemSeed=225
Expand All @@ -54,20 +54,27 @@ <h2>Problem 1</h2>

<h2>Problem 2</h2>
<p>
This is for debugging and shows all the details of the hash returned by PG.
By loading the graphs into separate tabs you can see that the two
graphs have different urls. This allows separation of
graphs, auxiliary html, and geogebra applets which might have the same
name and are loaded from problems with the same name but are supposed to be
two different exercises. (Usually the fact that the problems have different
seeds is enough to separate them but just in case you can set
different problemUUID/problemIdentifierPrefix values. problemUUID is the preferred
key name -- problemIdentifierPrefix also works for compatibility. )
</p>


<hr>
<iframe width="800" height="600"
src="http://127.0.0.1/webwork2/html2xml?
src="https://demo.webwork.rochester.edu/webwork2/html2xml?
&answersSubmitted=0
&sourceFilePath=setDemo/limits.pg
&problemSeed=225
&displayMode=MathJax
&courseID=daemon_course
&userID=daemon
&problemIdentifierPrefix=231
&problemUUID=231
&course_password=daemon
&outputformat=standard">
</iframe>
Expand Down
2 changes: 2 additions & 0 deletions lib/WeBWorK/PG.pm
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ sub defineProblemEnvir {
#$envir{psvn} = $set->psvn;
# to
$envir{psvn} = $psvn; #'problem set version number' (associated with homework set)
# MEG added the following. psvn is a unique id for the user_set record
$envir{psvn} = $envir{psvn}//$set->psvn; # use set value of psvn unless there is an explicit override.
# update problemUUID from submitted form
$envir{problemUUID} = $formFields->{problemUUID} //
$formFields->{problemIdentifierPrefix} //
Expand Down

0 comments on commit 55443f6

Please sign in to comment.