--- loncom/publisher/lonpublisher.pm 2005/06/23 22:46:00 1.198 +++ loncom/publisher/lonpublisher.pm 2005/06/29 17:46:20 1.200 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Publication Handler # -# $Id: lonpublisher.pm,v 1.198 2005/06/23 22:46:00 www Exp $ +# $Id: lonpublisher.pm,v 1.200 2005/06/29 17:46:20 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1647,10 +1647,16 @@ sub phasetwo { $r->register_cleanup(\¬ify); $registered_cleanup=1; } + +# ---------------------------------------------------------- Clear local caches + my $thisdistarget=$target; + $thisdistarget=~s/^\Q$docroot\E//; + &Apache::lonnet::devalidate_cache_new('resversion',$target); + &Apache::lonnet::devalidate_cache_new('meta', + &Apache::lonnet::declutter($thisdistarget)); + # ------------------------------------------------ Provide link to new resource unless ($batch) { - my $thisdistarget=$target; - $thisdistarget=~s/^\Q$docroot\E//; my $thissrc=$source; $thissrc=~s/^\/home\/(\w+)\/public_html/\/priv\/$1/; @@ -2061,6 +2067,7 @@ sub handler { $thisfn=~/\.(\w+)$/; my $thistype=$1; my $thisembstyle=&Apache::loncommon::fileembstyle($thistype); + if ($thistype eq 'page') { $thisembstyle = 'rat'; } $r->print('