--- rat/lonratedt.pm 2004/04/26 17:50:37 1.58
+++ rat/lonratedt.pm 2004/11/17 19:59:29 1.62
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Edit Handler for RAT Maps
#
-# $Id: lonratedt.pm,v 1.58 2004/04/26 17:50:37 www Exp $
+# $Id: lonratedt.pm,v 1.62 2004/11/17 19:59:29 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -706,14 +706,18 @@ sub smpedt {
my $tmpfn=&Apache::lonnet::filelocation('',$url).'.tmp';
my $targetmsg='';
if ($ENV{'form.save'}) {
- $targetmsg='Saving ...
';
copy($tmpfn,&Apache::lonnet::filelocation('',$url));
unlink($tmpfn);
my ($errtext,$fatal)=
&mapread(&Apache::lonnet::filelocation('',$url),'');
+ unless ($fatal) {
+ $targetmsg=''.&mt('Saved.').'
';
+ } else {
+ $targetmsg=''.&mt('An error occured while saving.').'
';
+ }
}
if ($ENV{'form.revert'}) {
- $targetmsg='Reverting ...
';
+ $targetmsg=''.&mt('Reverted.').'
';
unlink($tmpfn);
my ($errtext,$fatal)=
&mapread(&Apache::lonnet::filelocation('',$url),'');
@@ -973,10 +977,9 @@ sub smpedt {
# ----------------------------------------------------- Start simple RAT screen
my $editscript=&editscript('simple');
- my $bodytag=&Apache::loncommon::bodytag(undef,undef,undef,1).
- &Apache::loncommon::help_open_topic('Sequence_Simple_Editor_Creation').
- &Apache::loncommon::help_open_faq(6).
- &Apache::loncommon::help_open_bug('RAT');
+ my $bodytag=&Apache::loncommon::bodytag(undef,undef,undef,
+ ($ENV{'environment.remote'} ne 'off')).
+ &Apache::loncommon::help_open_menu('','Sequence_Simple_Editor_Creation','Sequence_Simple_Editor_Creation','',6,'RAT');
my %lt=&Apache::lonlocal::texthash(
'sa' => 'Save',
'nt' => 'New Title',
@@ -1132,8 +1135,7 @@ sub viewmap {
my ($r,$url,$adv,$errtext)=@_;
$r->print(''.
&Apache::loncommon::bodytag('Edit Content of a Map').
- &Apache::loncommon::help_open_faq(6).
- &Apache::loncommon::help_open_bug('RAT').
+ &Apache::loncommon::help_open_menu('','','','',6,'RAT').
&buttons($adv));
if ($errtext) {
$r->print($errtext.'