[LON-CAPA-cvs] cvs: loncom /interface londocs.pm
bisitz
bisitz@source.lon-capa.org
Wed, 17 Jun 2009 17:15:00 -0000
bisitz Wed Jun 17 17:15:00 2009 EDT
Modified files:
/loncom/interface londocs.pm
Log:
- Repaired javascript changes from rev. 1.369:
Added needed line breaks to allow the browser to interpret the first javascript line as script, not as comment
-> "re-initialize" button works again
- Corrected reinit URL: now coursedocs again (instead of roles)
- Don't misuse <h3> to highlight warning message
Index: loncom/interface/londocs.pm
diff -u loncom/interface/londocs.pm:1.371 loncom/interface/londocs.pm:1.372
--- loncom/interface/londocs.pm:1.371 Tue Jun 9 18:42:42 2009
+++ loncom/interface/londocs.pm Wed Jun 17 17:15:00 2009
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Documents
#
-# $Id: londocs.pm,v 1.371 2009/06/09 18:42:42 tempelho Exp $
+# $Id: londocs.pm,v 1.372 2009/06/17 17:15:00 bisitz Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -2502,18 +2502,18 @@
$message='Changes will become active for your current session after [_1], or the next time you log in.';
}
$r->print("\n\n".
-'<script type="text/javascript">'.
-'// <![CDATA['.
-'function reinit(tf) { tf.submit();'.$postexec.' }'.
-'// ]]>'.
+'<script type="text/javascript">'."\n".
+'// <![CDATA['."\n".
+'function reinit(tf) { tf.submit();'.$postexec.' }'."\n".
+'// ]]>'."\n".
'</script>'."\n".
-'<form name="reinitform" method="post" action="/adm/roles" target="loncapaclient">'.
+'<form name="reinitform" method="post" action="/adm/coursedocs" target="loncapaclient">'.
'<input type="hidden" name="orgurl" value="'.$url.
-'" /><input type="hidden" name="selectrole" value="1" /><h3><span class="LC_warning">'.
+'" /><input type="hidden" name="selectrole" value="1" /><p class="LC_warning">'.
&mt($message,' <input type="hidden" name="'.
$env{'request.role'}.'" value="1" /><input type="button" value="'.
&mt('re-initializing '.$course_type).'" onclick="reinit(this.form)" />').
-$help{'Caching'}.'</span></h3></form>'."\n\n");
+$help{'Caching'}.'</p></form>'."\n\n");
}
@@ -2670,10 +2670,10 @@
}
# -------------------------------------------------------------------- Body tag
$script = '<script type="text/javascript">'."\n"
- .'// <![CDATA['
- .$script
- .'// ]]>'
- ."\n".'</script>';
+ .'// <![CDATA['."\n"
+ .$script."\n"
+ .'// ]]>'."\n"
+ .'</script>'."\n";
my $brcrum = [{href=>"/adm/createuser",text=>"$type Documents"}];
$r->print(&Apache::loncommon::start_page("$type Documents", $script,
{'force_register' => $showdoc,
@@ -2951,11 +2951,11 @@
}
my $postexec='';
if ($folder eq 'default') {
- $r->print('<script type="text/javascript">'
- .'// <![CDATA['
- .'this.window.name="loncapaclient";'
- .'// ]]>'
- .'</script>'
+ $r->print('<script type="text/javascript">'."\n"
+ .'// <![CDATA['."\n"
+ .'this.window.name="loncapaclient";'."\n"
+ .'// ]]>'."\n"
+ .'</script>'."\n"
);
} else {
#$postexec='self.close();';