[LON-CAPA-cvs] cvs: loncom /homework grades.pm
albertel
lon-capa-cvs@mail.lon-capa.org
Tue, 11 Apr 2006 20:51:47 -0000
albertel Tue Apr 11 16:51:47 2006 EDT
Modified files:
/loncom/homework grades.pm
Log:
- start_page
Index: loncom/homework/grades.pm
diff -u loncom/homework/grades.pm:1.350 loncom/homework/grades.pm:1.351
--- loncom/homework/grades.pm:1.350 Tue Apr 11 16:20:53 2006
+++ loncom/homework/grades.pm Tue Apr 11 16:51:46 2006
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# The LON-CAPA Grading handler
#
-# $Id: grades.pm,v 1.350 2006/04/11 20:20:53 albertel Exp $
+# $Id: grades.pm,v 1.351 2006/04/11 20:51:46 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -1143,7 +1143,7 @@
my $iconpath = $request->dir_config('lonIconsURL');
&commonJSfunctions($request);
- my $inner_js=<<INNERJS;
+ my $inner_js_msg_central=<<INNERJS;
<script text="text/javascript">
function checkInput() {
opener.document.SCORE.msgsub.value = opener.checkEntities(document.msgcenter.msgsub.value);
@@ -1184,12 +1184,37 @@
</script>
INNERJS
- my $start_page =
- &Apache::loncommon::start_page('MessageCentral',$inner_js,
+ my $inner_js_highlight_central=<<INNERJS;
+ <script type="text/javascript">
+ function updateChoice(flag) {
+ opener.document.SCORE.kwclr.value = opener.radioSelection(document.hlCenter.kwdclr);
+ opener.document.SCORE.kwsize.value = opener.radioSelection(document.hlCenter.kwdsize);
+ opener.document.SCORE.kwstyle.value = opener.radioSelection(document.hlCenter.kwdstyle);
+ opener.document.SCORE.refresh.value = "on";
+ if (opener.document.SCORE.keywords.value!=""){
+ opener.document.SCORE.submit();
+ }
+ self.close()
+ }
+</script>
+INNERJS
+
+ my $start_page_msg_central =
+ &Apache::loncommon::start_page('Message Central',$inner_js_msg_central,
+ {'js_ready' => 1,
+ 'only_body' => 1,
+ 'bgcolor' =>'#FFFFFF',});
+ my $end_page_msg_central =
+ &Apache::loncommon::end_page({'js_ready' => 1});
+
+
+ my $start_page_highlight_central =
+ &Apache::loncommon::start_page('Highlight Central',
+ $inner_js_highlight_central,
{'js_ready' => 1,
'only_body' => 1,
'bgcolor' =>'#FFFFFF',});
- my $end_page =
+ my $end_page_highlight_central =
&Apache::loncommon::end_page({'js_ready' => 1});
my $docopen=&Apache::lonhtmlcommon::javascript_docopen();
@@ -1307,7 +1332,7 @@
pWin.focus();
pDoc = pWin.document;
pDoc.$docopen;
- pDoc.write('$start_page');
+ pDoc.write('$start_page_msg_central');
pDoc.write("<form action=\\"inactive\\" name=\\"msgcenter\\">");
pDoc.write("<input value=\\""+usrctr+"\\" name=\\"usrctr\\" type=\\"hidden\\">");
@@ -1348,7 +1373,7 @@
pDoc.write("<input type=\\"button\\" value=\\"Save\\" onClick=\\"javascript:checkInput()\\"> ");
pDoc.write("<input type=\\"button\\" value=\\"Cancel\\" onClick=\\"self.close()\\"><br /><br />");
pDoc.write("</form>");
- pDoc.write('$end_page');
+ pDoc.write('$end_page_msg_central');
pDoc.close();
}
@@ -1394,26 +1419,7 @@
hwdWin.focus();
var hDoc = hwdWin.document;
hDoc.$docopen;
- hDoc.write("<html><head>");
- hDoc.write("<title>Highlight Central</title>");
-
- hDoc.write("<script language=javascript>");
- hDoc.write("function updateChoice(flag) {");
- hDoc.write(" opener.document.SCORE.kwclr.value = opener.radioSelection(document.hlCenter.kwdclr);");
- hDoc.write(" opener.document.SCORE.kwsize.value = opener.radioSelection(document.hlCenter.kwdsize);");
- hDoc.write(" opener.document.SCORE.kwstyle.value = opener.radioSelection(document.hlCenter.kwdstyle);");
- hDoc.write(" opener.document.SCORE.refresh.value = \\"on\\";");
- hDoc.write(" if (opener.document.SCORE.keywords.value!=\\"\\"){");
- hDoc.write(" opener.document.SCORE.submit();");
- hDoc.write(" }");
- hDoc.write(" self.close()");
- hDoc.write("}");
-
- hDoc.write("<");
- hDoc.write("/script>");
-
- hDoc.write("</head><body bgcolor=white>");
-
+ hDoc.write('$start_page_highlight_central');
hDoc.write("<form action=\\"inactive\\" name=\\"hlCenter\\">");
hDoc.write("<font color=\\"green\\" size=+1> Keyword Highlight Options</font><br /><br />");
@@ -1441,7 +1447,7 @@
hDoc.write("<input type=\\"button\\" value=\\"Save\\" onClick=\\"javascript:updateChoice(1)\\"> ");
hDoc.write("<input type=\\"button\\" value=\\"Cancel\\" onClick=\\"self.close()\\"><br /><br />");
hDoc.write("</form>");
- hDoc.write("</body></html>");
+ hDoc.write('$end_page_highlight_central');
hDoc.close();
}