[system] / branches / rel-2-1-a1 / webwork-modperl / conf / templates / gw.template Repository:
ViewVC logotype

View of /branches/rel-2-1-a1/webwork-modperl/conf/templates/gw.template

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3276 - (download) (annotate)
Thu Jun 9 15:00:13 2005 UTC (7 years, 11 months ago) by glarose
File size: 10895 byte(s)
Gateway update: revise gateway template file

    1 <!DOCTYPE html
    2   PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    3   SYSTEM "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    4 
    5 <!--
    6 ################################################################################
    7 # WeBWorK Online Homework Delivery System
    8 # Copyright © 2000-2003 The WeBWorK Project, http://openwebwork.sf.net/
    9 # $CVSHeader: webwork2/conf/templates/ur.template,v 1.29.2.2 2004/07/26 15:11:16 gage Exp $
   10 #
   11 # This program is free software; you can redistribute it and/or modify it under
   12 # the terms of either: (a) the GNU General Public License as published by the
   13 # Free Software Foundation; either version 2, or (at your option) any later
   14 # version, or (b) the "Artistic License" which comes with this package.
   15 #
   16 # This program is distributed in the hope that it will be useful, but WITHOUT
   17 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
   18 # FOR A PARTICULAR PURPOSE.  See either the GNU General Public License or the
   19 # Artistic License for more details.
   20 ################################################################################
   21 -->
   22 
   23 <html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
   24 <head>
   25 <title><!--#path style="text" text=" : " textonly="1"--></title>
   26 <!--#head-->
   27 <style type="text/css">
   28 
   29 /********************/
   30 /* template classes */
   31 /********************/
   32 
   33 body { margin: 0px; }
   34 
   35 /* left table cell, contains logo and menus */
   36 td.LeftPanel { background-color: #003366; color: white; white-space: nowrap; width: 1em; }
   37 td.LeftPanel a:link,
   38 td.LeftPanel a:visited { color: #FF9933; }
   39 
   40 div.Logo {  }
   41 div.Links { font-size: small; }
   42 div.Siblings { font-size: small; }
   43 div.Options { font-size: small; }
   44 
   45 /* top table cell, contains login message and path */
   46 td.TopPanel { background-color: #003366; color: white; height: 1; }
   47 td.TopPanel a:link,
   48 td.TopPanel a:visited { color: #FF9933; }
   49 
   50 
   51 *.LoginStatus { text-align: right; font-size: small; position:absolute; right: 0; }
   52 td.Timestamp   { text-align: left;  font-size: small; font-style: italic; }
   53 
   54 *.Path {  }
   55 
   56 /* main content panel, contains body */
   57 td.ContentPanel { background-color: white; color: black; }
   58 td.ContentPanel a:link,
   59 td.ContentPanel a:visited { color: blue; }
   60 td.ContentPanel a:active { color: red; }
   61 
   62 /* contains info */
   63 td.InfoPanel { background-color: #DDDDDD; color: black; width: 15% }
   64 td.InfoPanel a:link,
   65 td.InfoPanel a:visited { color: blue; }
   66 td.InfoPanel a:active { color: red; }
   67 
   68 div.Info {  }
   69 div.Nav {  }
   70 div.Title { font-size: 16pt; }
   71 div.SubmitError { color: red; font-style: italic; }
   72 div.Message { font-style: italic; }
   73 div.Body {  }
   74 div.Warnings {  }
   75 
   76 /* background colors for success and failure messages */
   77 div.ResultsWithoutError { background-color: #66ff99 } /* light green */
   78 div.ResultsWithError    { background-color: #ffcccc } /* light red */
   79 
   80 /* text colors for published and unpublished sets */
   81 font.Published   { font-style: normal; font-weight: bold;   color: #000000; } /* black */
   82 font.Unpublished { font-style: italic; font-weight: normal; color: #aaaaaa; } /* light grey */
   83 
   84 /* text colors for Auditing, Current, and Dropped students */
   85 div.Audit { font-style: normal; color: black; }
   86 div.Enrolled  { font-weight: bold;  color: black; }
   87 div.Drop  { font-style: italic; color: grey; }
   88 
   89 /*******************/
   90 /* general classes */
   91 /*******************/
   92 
   93 p.emphasis { font-style:italic; }
   94 
   95 /************************/
   96 /* new standard classes */
   97 /************************/
   98 
   99 /* tables used for laying out form fields shouldn't have a border */
  100 table.FormLayout { border: 0; }
  101 table.FormLayout tr { vertical-align: top; }
  102 table.FormLayout th.LeftHeader { text-align: right; white-space: nowrap; }
  103 table.FormLayout tr.ButtonRow { text-align: left; }
  104 table.FormLayout tr.ButtonRowCenter { text-align: center; }
  105 
  106 /* for problems which are rendered by themselves, e.g., by Set Maker */
  107 div.RenderSolo { background-color: #E0E0E0; color: black; }
  108 
  109 /* minimal style for lists of links (generated by the links escape) */
  110 ul.LinksMenu { list-style: none; margin-left: 0; padding-left: 0; }
  111 ul.LinksMenu ul { list-style: none; margin-left: 0.5em; padding-left: 0; }
  112 
  113 /*************************/
  114 /* WeBWorK::HTML widgets */
  115 /*************************/
  116 
  117 /* WeBWorK::HTML::ScrollingRecordList */
  118 div.ScrollingRecordList { padding: 1em; white-space: nowrap; border: thin solid gray; }
  119 div.ScrollingRecordList select.ScrollingRecordList { width: 99%; }
  120 
  121 /*************************************************************************/
  122 /* classes used in Problem.pm (replace these with new standard classes?) */
  123 /*************************************************************************/
  124 
  125 table.attemptResults {
  126   border-style: outset;
  127   border-width: 1px;
  128   margin: 0px 10pt;
  129   border-spacing: 1px;
  130 }
  131 table.attemptResults td,
  132 table.attemptResults th {
  133   border-style: inset;
  134   border-width: 1px;
  135   text-align: center;
  136   width: 15ex;
  137   background-color: #DDDDDD;
  138 }
  139 div.problemHeader { float: left; }
  140 div.problem { clear: both; background-color: #E0E0E0; color: black; }
  141 .parsehilight { background-color:yellow; }
  142 
  143 </style>
  144 
  145 <style type="text/css">
  146 /******************/
  147 /* gateway styles */
  148 /******************/
  149 
  150 div.gwMessage { background-color:#dddddd; color: black; }
  151 div.gwTiming {
  152   background-color:#ddddff;
  153   color: black;
  154   margin-top: 10px;
  155   margin-bottom: 0px;
  156 }
  157 div.gwWarning { background-color:#ffffdd; color: black; }
  158 
  159 span.resultsWithError { background-color: #ffcccc; color: black; }
  160 span.resultsWithoutError { background-color: #66ff99; color: black; }
  161 div.gwCorrect { background-color: #66ff99; color: black; }
  162 div.gwIncorrect { background-color: #ff9999; color: black; }
  163 
  164 div.gwProblem {
  165   clear: both;
  166   background-color: #E0E0E0;
  167   color: black;
  168   padding: 3px;
  169   border: solid black 1px;
  170 }
  171 div.gwSoln {
  172 /*  background-color: #e0e0ff; */
  173   background-color: transparent;
  174   color: black;
  175 /*  padding: 2px; */,
  176 /*  border: dashed black 1px; */
  177 }
  178 div.gwSoln b { color: navy; }
  179 
  180 p.gwPreview {
  181   font-size: smaller;
  182   text-align: right;
  183   margin-top: 0px;
  184   margin-bottom: 0px;
  185 }
  186 
  187 table.gwAttemptResults {
  188   border-width: 0px;
  189 }
  190 table.gwAttemptResults td.label {
  191   font-weight: bold;
  192   background-color: transparent;
  193   color: navy;
  194 }
  195 table.gwAttemptResults td.output {
  196         padding: 2px;
  197   border: solid black 1px;
  198   background-color: #eeeeee;
  199 }
  200 
  201 </style>
  202 <script language="javascript" type="text/javascript">
  203 function jumpTo(ref) {  // scrolling javascript function
  204     if ( ref ) {
  205         var pn = ref - 1; // we start anchors at 1, not zero
  206         if ( navigator.appName == "Netscape" &&
  207              parseFloat(navigator.appVersion) < 5 ) {
  208             var xpos = document.anchors[pn].x;
  209             var ypos = document.anchors[pn].y;
  210         } else {
  211             var xpos = document.anchors[pn].offsetLeft;
  212             var ypos = document.anchors[pn].offsetTop;
  213         }
  214         if ( window.scrollTo == null ) { // cover for anyone
  215             window.scroll(xpos,ypos);    //   lacking js1.2
  216         } else {
  217             window.scrollTo(xpos,ypos);
  218         }
  219     }
  220     return false; // prevent link from being followed
  221 }
  222 
  223 // timer for gateway
  224 var theTime = -1;      // -1 before we've initialized
  225 var alerted = -1;      // -1 = no alert set; 1 = 1st alert set
  226                        // this shouldn't really be needed
  227 
  228 function runtimer() {
  229 // aesthetically this is displeasing: we're assuming that the
  230 // ContentGenerator will put the appropriate form elements in that
  231 // page for us to manipulate.  even with error checking, it seems sort
  232 // of odd.
  233     if ( document.gwtimer == null ) {  // no timer
  234         return;
  235     } else {
  236         var tm = document.gwtimer.gwtime;
  237         var st = document.gwtimer.gwpagetimeleft.value;
  238 
  239         if ( st == 0 ) {                  // no time limit
  240             return;
  241         } else {
  242             if ( theTime == -1 ) {
  243                 theTime = st;
  244                 tm.value = toMinSec(theTime);
  245                 setTimeout("runtimer()", 1000);  // 1000 ms = 1 sec
  246             } else if ( theTime == 0 && alerted != 3 ) {
  247           alert("* You are out of time! *");
  248     alerted = 3;
  249       } else if ( alerted != 3 ) {
  250           theTime--;
  251                 tm.value = toMinSec(theTime);
  252                 setTimeout("runtimer()", 1000);  // 1000 ms = 1 sec
  253     if ( theTime == 35 && alerted != 2 ) { // time is in seconds
  254         alert("* You have only about 30 seconds to complete " +
  255               "this assignment.  Press Grade very soon! *\n" +
  256         "* The timer stops while this alert box is open. *");
  257         alerted = 2;
  258         theTime -= 5;
  259                 } else if ( theTime == 75 && alerted != 1) {
  260         alert("* You have only about a minute left " +
  261               "to complete this assignment! *\n" +
  262         "* The timer stops while this alert box is open. *");
  263                     alerted = 1;
  264         theTime -= 5;
  265                 }
  266             }
  267         }
  268     }
  269 }
  270 function toMinSec(t) {
  271 // convert to min:sec
  272     mn = Math.floor(t/60);
  273     sc = t - 60*mn;
  274     if ( mn < 10 && mn > -1 ) {
  275         mn = "0" + mn;
  276     }
  277     if ( sc < 10 ) {
  278         sc = "0" + sc;
  279     }
  280     return mn + ":" + sc;
  281 }
  282 </script>
  283 </head>
  284 <body onload="runtimer();">
  285 <table width="100%" cellpadding="10" cellspacing="0" border="0">
  286   <tr valign="top">
  287 <!-- removed left sidebar -->
  288     <!--#if can="info"-->
  289     <td class="TopPanel" colspan="2">
  290     <!--#else-->
  291     <td class="TopPanel" >
  292     <!--#endif-->
  293         <div style="position:relative; width:100%;">
  294         <!--#if can="path"-->
  295         <span class="Path">
  296           <!--#path style="text" image="/webwork2_files/images/right_arrow.png" text=" > "-->
  297         </span>
  298         <!--#endif-->
  299 
  300         <!--#if loggedin="1"-->
  301           <!--#if can="loginstatus"-->
  302 
  303           <span class="LoginStatus">
  304 
  305             <!--#loginstatus-->
  306           </span>
  307           <!--#endif-->
  308         <!--#endif-->
  309       </div>
  310     </td>
  311   </tr>
  312   <tr valign="top">
  313     <!--#if warnings="1"-->
  314     <td class="ContentPanelError" bgcolor="#ffcccc">
  315     <!--#else-->
  316     <td class="ContentPanel" bgcolor="#ffffff">
  317     <!--#endif-->
  318 <!-- removed nav button to go up -->
  319       <!--#if can="title"-->
  320       <div class="Title">
  321         <!--#title-->
  322       </div>
  323       <!--#endif-->
  324       <!--#if can="message"-->
  325         <div class="Message">
  326           <!--#message-->
  327         </div>
  328       <!--#endif-->
  329 
  330       <!--#if can="submiterror"-->
  331         <div class="SubmitError">
  332           <!--#submiterror-->
  333         </div>
  334       <!--#endif-->
  335       <!--#if can="body"-->
  336       <div class="Body">
  337         <!--#body-->
  338       </div>
  339       <!--#endif-->
  340       <!--#if warnings="1"-->
  341       <hr>
  342       <div class="Warnings">
  343         <!--#warnings-->
  344       </div>
  345       <!--#endif-->
  346       <!--#if can="message"-->
  347         <div class="Message">
  348           <!--#message-->
  349         </div>
  350       <!--#endif-->
  351     </td>
  352     <!--#if can="info"-->
  353     <td class="InfoPanel">
  354       <div class="Info">
  355         <!--#info-->
  356       </div>
  357     </td>
  358     <!--#endif-->
  359   </tr>
  360   <tr>
  361       <td class = "Timestamp", colspan=3>
  362           Updated: <!--#timestamp-->
  363       </td>
  364   </tr>
  365 </table>
  366 </body>
  367 </html>

aubreyja at gmail dot com
ViewVC Help
Powered by ViewVC 1.0.9