--- loncom/xml/londefdef.pm 2000/11/06 17:03:29 1.11 +++ loncom/xml/londefdef.pm 2001/01/04 19:15:20 1.14 @@ -2,7 +2,7 @@ # Tags Default Definition Module # # last modified 06/26/00 by Alexander Sakharuk -# 11/6 Gerd Kortemeyer +# 11/6,11/30 Gerd Kortemeyer package Apache::londefdef; @@ -16,13 +16,13 @@ sub BEGIN { #===================================================================== TAG SUBROUTINES #-- sub start_output { - my ($target,$token,$parstack,$parser) = @_; + my ($target,$token) = @_; $Apache::lonxml::textredirection = 1; my $result = ''; return $result; } sub end_output { - my ($target,$token,$parstack,$parser) = @_; + my ($target,$token) = @_; $Apache::lonxml::textredirection = 0; my $result = ''; return $result; @@ -213,6 +213,10 @@ sub BEGIN { if ($target eq 'web') { $currentstring = $token->[4]; } + if ($target eq 'meta') { + $currentstring=''; + &start_output(); + } return $currentstring; } sub end_title { @@ -220,6 +224,10 @@ sub BEGIN { my $currentstring = ''; if ($target eq 'web') { $currentstring = $token->[2]; + } + if ($target eq 'meta') { + &end_output(); + $currentstring=''; } return $currentstring; } @@ -230,6 +238,18 @@ sub BEGIN { if ($target eq 'web') { $currentstring = $token->[4]; } + if ($target eq 'meta') { + unless ($token->[2]->{'http-equiv'}) { + my $name=$token->[2]->{'name'}; + $name=~tr/A-Z/a-z/; + $name=~s/\s/\_/g; + if ($name) { + $currentstring='<'.$name.'>'. + $token->[2]->{'content'}. + ''; + } + } + } return $currentstring; } sub end_meta { @@ -333,7 +353,10 @@ sub BEGIN { $currentstring .= $token->[4]; } elsif ($target eq 'tex') { $currentstring .= "\\chapter{ "; - } + } elsif ($target eq 'meta') { + $currentstring=''; + &start_output(); + } return $currentstring; } sub end_h1 { @@ -343,7 +366,10 @@ sub BEGIN { $currentstring .= $token->[2]; } elsif ($target eq 'tex') { $currentstring .= "}"; - } + } elsif ($target eq 'meta') { + &end_output(); + $currentstring=''; + } return $currentstring; } #----------------------------------------------------------------------------

tag @@ -724,13 +750,21 @@ sub BEGIN { } #---------------------------------------------------------------------- tag sub start_basefont { - my ($target,$token) = @_; - my $currentstring = ''; - if ($target eq 'web') { - $currentstring = $token->[4]; - } - return $currentstring; - } + my ($target,$token) = @_; + my $currentstring = ''; + if ($target eq 'web') { + $currentstring = $token->[4]; + } + return $currentstring; + } + sub end_basefont { + my ($target,$token) = @_; + my $currentstring = ''; + if ($target eq 'web') { + $currentstring = $token->[4]; + } + return $currentstring; + } #-------------------------------------------------------------------------- tag sub start_font { my ($target,$token) = @_;