version 1.58, 2001/08/18 16:08:34
|
version 1.64, 2001/08/20 19:27:26
|
Line 2
|
Line 2
|
# definition of tags that give a structure to a document |
# definition of tags that give a structure to a document |
# 2/19 Guy |
# 2/19 Guy |
# 6/26/2001 fixed extra web display at end of <web></web> tags |
# 6/26/2001 fixed extra web display at end of <web></web> tags |
# 8/17,8/18 Gerd Kortemeyer |
# 8/17,8/18,8/20 Gerd Kortemeyer |
|
|
package Apache::structuretags; |
package Apache::structuretags; |
|
|
Line 98 sub start_problem {
|
Line 98 sub start_problem {
|
my $token=$Apache::lonhomework::history{"resource.0.outtoken"}; |
my $token=$Apache::lonhomework::history{"resource.0.outtoken"}; |
if (($ENV{'form.doescheckout'}) && (!$token)) { |
if (($ENV{'form.doescheckout'}) && (!$token)) { |
$token=&Apache::lonxml::maketoken(); |
$token=&Apache::lonxml::maketoken(); |
|
$Apache::lonhomework::history{"resource.0.outtoken"}=$token; |
} |
} |
$body_tag_start.=&Apache::lonxml::printtokenheader($target,$token); |
$body_tag_start.=&Apache::lonxml::printtokenheader($target,$token); |
} |
} |
if ($target eq 'meta') { |
|
print "Cool, I was called"; |
|
|
|
return (<<ENDSTORES); |
|
<stores part="0" name="outtoken" type="string" |
|
display="Document ID checked out" /> |
|
<stores part="0" name="checkouttime" type="date" |
|
display="Time checked out" /> |
|
<stores part="0" name="outremote" type="string" |
|
display="Client IP checked out from" /> |
|
|
|
<stores part="0" name="intoken" type="string" |
|
display="Document ID checked in" /> |
|
<stores part="0" name="checkintime" type="date" |
|
display="Time checked in" /> |
|
<stores part="0" name="inremote" type="string" |
|
display="Client IP checked in from" /> |
|
ENDSTORES |
|
} |
|
} |
} |
if ($target eq 'web' || $target eq 'grade') { |
if ($target eq 'web' || $target eq 'grade') { |
($status,$accessmsg) = &Apache::lonhomework::check_access('0'); |
($status,$accessmsg) = &Apache::lonhomework::check_access('0'); |
Line 147 Checking out resources is subject to cou
|
Line 129 Checking out resources is subject to cou
|
credit even if done erroneously.<p /> |
credit even if done erroneously.<p /> |
</font> |
</font> |
<form method=post> |
<form method=post> |
<input type=submit name="doescheckout" |
<input type=button name="doescheckout" |
value="Check out Exam for Viewing" /> |
value="Check out Exam for Viewing" |
|
onClick="if (confirm('Check out Exam?')) { this.form.submit(); }" /> |
</form> |
</form> |
ENDCHECKOUT |
ENDCHECKOUT |
} |
} |