version 1.230, 2003/09/17 21:29:44
|
version 1.234, 2003/09/24 15:58:06
|
Line 107 sub real_handler {
|
Line 107 sub real_handler {
|
# Handle header-only request |
# Handle header-only request |
if ($r->header_only) { |
if ($r->header_only) { |
if ($ENV{'browser.mathml'}) { |
if ($ENV{'browser.mathml'}) { |
$r->content_type('text/xml'); |
&Apache::loncommon::content_type($r,'text/xml'); |
} else { |
} else { |
$r->content_type('text/html'); |
&Apache::loncommon::content_type($r,'text/html'); |
} |
} |
$r->send_http_header; |
$r->send_http_header; |
return OK; |
return OK; |
Line 117 sub real_handler {
|
Line 117 sub real_handler {
|
|
|
# Send header, don't cache this page |
# Send header, don't cache this page |
if ($ENV{'browser.mathml'}) { |
if ($ENV{'browser.mathml'}) { |
$r->content_type('text/xml'); |
&Apache::loncommon::content_type($r,'text/xml'); |
} else { |
} else { |
$r->content_type('text/html'); |
&Apache::loncommon::content_type($r,'text/html'); |
} |
} |
&Apache::loncommon::no_cache($r); |
&Apache::loncommon::no_cache($r); |
$r->send_http_header; |
$r->send_http_header; |
Line 432 sub timeToHumanString {
|
Line 432 sub timeToHumanString {
|
if (!$time) { |
if (!$time) { |
return &mt('never'); |
return &mt('never'); |
} |
} |
unless (&Apache::loncommon::current_language()=~/^en/) { |
unless (&Apache::lonlocal::current_language()=~/^en/) { |
return localtime($time); |
return localtime($time); |
} |
} |
my $now = time(); |
my $now = time(); |
Line 3547 sub responseType {
|
Line 3547 sub responseType {
|
my $part = shift; |
my $part = shift; |
|
|
$self->extractParts(); |
$self->extractParts(); |
return $self->{RESPONSE_TYPES}->{$part}; |
return @{$self->{RESPONSE_TYPES}->{$part}}; |
} |
} |
|
|
sub responseIds { |
sub responseIds { |
Line 3555 sub responseIds {
|
Line 3555 sub responseIds {
|
my $part = shift; |
my $part = shift; |
|
|
$self->extractParts(); |
$self->extractParts(); |
return $self->{RESPONSE_IDS}->{$part}; |
return @{$self->{RESPONSE_IDS}->{$part}}; |
} |
} |
|
|
# Private function: Extracts the parts information, both part names and |
# Private function: Extracts the parts information, both part names and |
Line 3629 sub extractParts {
|
Line 3629 sub extractParts {
|
my @otherChunks = @partChunks[$i+1..$#partChunks]; |
my @otherChunks = @partChunks[$i+1..$#partChunks]; |
my $responseId = join('_', @otherChunks); |
my $responseId = join('_', @otherChunks); |
push @{$responseIdHash{$partIdSoFar}}, $responseId; |
push @{$responseIdHash{$partIdSoFar}}, $responseId; |
$responseTypeHash{$partIdSoFar} = $responseType; |
push @{$responseTypeHash{$partIdSoFar}}, $responseType; |
last; |
|
} |
} |
} |
} |
} |
} |