version 1.94, 2001/06/16 15:08:09
|
version 1.96, 2001/06/16 18:34:31
|
Line 11
|
Line 11
|
# 5/27 H. K. Ng |
# 5/27 H. K. Ng |
# 6/2,6/3,6/8,6/9 Gerd Kortemeyer |
# 6/2,6/3,6/8,6/9 Gerd Kortemeyer |
# 6/12,6/13 H. K. Ng |
# 6/12,6/13 H. K. Ng |
|
# 6/16 Gerd Kortemeyer |
|
|
package Apache::lonxml; |
package Apache::lonxml; |
use vars |
use vars |
Line 152 ENDPARM
|
Line 153 ENDPARM
|
menu.switchbutton |
menu.switchbutton |
(9,2,'vbkm.gif','view','bookmark','edit_bookmarks()'); |
(9,2,'vbkm.gif','view','bookmark','edit_bookmarks()'); |
menu.switchbutton |
menu.switchbutton |
(9,3,'anot.gif','anno-','tations','gopost("/adm/annotations",currentURL)'); |
(9,3,'anot.gif','anno-','tations','annotate()'); |
|
|
$hwkadd |
$hwkadd |
} |
} |
|
|
Line 225 sub printalltags {
|
Line 225 sub printalltags {
|
|
|
sub xmlparse { |
sub xmlparse { |
my ($target,$content_file_string,$safeinit,%style_for_target) = @_; |
my ($target,$content_file_string,$safeinit,%style_for_target) = @_; |
if ($target eq 'meta') { |
|
$Apache::lonxml::redirection = 0; |
&setup_globals($target); |
$Apache::lonxml::metamode = 1; |
|
$Apache::lonxml::evaluate = 1; |
|
$Apache::lonxml::import = 0; |
|
} elsif ($target eq 'grade') { |
|
&startredirection; |
|
$Apache::lonxml::metamode = 0; |
|
$Apache::lonxml::evaluate = 1; |
|
$Apache::lonxml::import = 1; |
|
} elsif ($target eq 'modified') { |
|
$Apache::lonxml::redirection = 0; |
|
$Apache::lonxml::metamode = 0; |
|
$Apache::lonxml::evaluate = 0; |
|
$Apache::lonxml::import = 0; |
|
} else { |
|
$Apache::lonxml::redirection = 0; |
|
$Apache::lonxml::metamode = 0; |
|
$Apache::lonxml::evaluate = 1; |
|
$Apache::lonxml::import = 1; |
|
} |
|
#&printalltags(); |
#&printalltags(); |
my @pars = (); |
my @pars = (); |
@Apache::lonxml::pwd=(); |
@Apache::lonxml::pwd=(); |
Line 472 sub callsub {
|
Line 453 sub callsub {
|
return $currentstring; |
return $currentstring; |
} |
} |
|
|
|
sub setup_globals { |
|
my ($target)=@_; |
|
if ($target eq 'meta') { |
|
$Apache::lonxml::redirection = 0; |
|
$Apache::lonxml::metamode = 1; |
|
$Apache::lonxml::evaluate = 1; |
|
$Apache::lonxml::import = 0; |
|
} elsif ($target eq 'grade') { |
|
&startredirection; |
|
$Apache::lonxml::metamode = 0; |
|
$Apache::lonxml::evaluate = 1; |
|
$Apache::lonxml::import = 1; |
|
} elsif ($target eq 'modified') { |
|
$Apache::lonxml::redirection = 0; |
|
$Apache::lonxml::metamode = 0; |
|
$Apache::lonxml::evaluate = 0; |
|
$Apache::lonxml::import = 0; |
|
} elsif ($target eq 'edit') { |
|
$Apache::lonxml::redirection = 0; |
|
$Apache::lonxml::metamode = 0; |
|
$Apache::lonxml::evaluate = 0; |
|
$Apache::lonxml::import = 0; |
|
} else { |
|
$Apache::lonxml::redirection = 0; |
|
$Apache::lonxml::metamode = 0; |
|
$Apache::lonxml::evaluate = 1; |
|
$Apache::lonxml::import = 1; |
|
} |
|
} |
|
|
sub init_safespace { |
sub init_safespace { |
my ($target,$safeeval,$safehole,$safeinit) = @_; |
my ($target,$safeeval,$safehole,$safeinit) = @_; |
$safeeval->permit("entereval"); |
$safeeval->permit("entereval"); |
Line 809 ENDNOTFOUND
|
Line 820 ENDNOTFOUND
|
|
|
sub debug { |
sub debug { |
if ($Apache::lonxml::debug eq 1) { |
if ($Apache::lonxml::debug eq 1) { |
print "DEBUG:".$_[0]."<br />\n"; |
print("DEBUG:".$_[0]."<br />\n"); |
} |
} |
} |
} |
|
|