--- loncom/xml/londefdef.pm 2007/05/10 09:50:10 1.365 +++ loncom/xml/londefdef.pm 2007/06/19 19:40:07 1.367 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Tags Default Definition Module # -# $Id: londefdef.pm,v 1.365 2007/05/10 09:50:10 foxr Exp $ +# $Id: londefdef.pm,v 1.367 2007/06/19 19:40:07 banghart Exp $ # # # Copyright Michigan State University Board of Trustees @@ -516,6 +516,17 @@ sub end_accessrule { return $currentstring; } +sub generate_css_links { + my $links; + my $css_href = &Apache::lonnet::EXT('resource.0.cssfile'); + if ($css_href =~ /\S/) { + &Apache::lonxml::extlink($css_href); + $links .= + ''; + } + return $links; +} + #--
tag (end tag required) sub start_body { my ($target,$token,$tagstack,$parstack,$parser,$safeeval) = @_; @@ -530,9 +541,13 @@ sub start_body { if (&is_inside_of($tagstack, "head")) { &end_head(@_); } + + my $extra_head = &generate_css_links(); + $currentstring = &Apache::loncommon::start_page($Apache::londefdef::title, - $Apache::londefdef::head, + $Apache::londefdef::head + .$extra_head, {'add_entries' => $token->[2], 'no_title' => 1, 'force_register' => 1}); @@ -2988,7 +3003,7 @@ sub start_img { } elsif ($target eq 'edit') { $currentstring .=&Apache::edit::tag_start($target,$token); $currentstring .=&Apache::edit::text_arg('Image Url:','src',$token,70). - &Apache::edit::browse('src',undef,'alt').' '. + &Apache::edit::browse('src',undef,'alt','gif,jpg,png,jpeg').' '. &Apache::edit::search('src',undef,'alt').'