| … | |
… | |
| 146 | /******************/ |
146 | /******************/ |
| 147 | /* gateway styles */ |
147 | /* gateway styles */ |
| 148 | /******************/ |
148 | /******************/ |
| 149 | |
149 | |
| 150 | div.gwMessage { background-color:#dddddd; color: black; } |
150 | div.gwMessage { background-color:#dddddd; color: black; } |
| 151 | div.gwTiming { background-color:#ddddff; color: black; } |
151 | div.gwTiming { |
|
|
152 | background-color:#ddddff; |
|
|
153 | color: black; |
|
|
154 | margin-top: 10px; |
|
|
155 | margin-bottom: 0px; |
|
|
156 | } |
| 152 | div.gwWarning { background-color:#ffffdd; color: black; } |
157 | div.gwWarning { background-color:#ffffdd; color: black; } |
| 153 | |
158 | |
| 154 | span.resultsWithError { background-color: #ffcccc; color: black; } |
159 | span.resultsWithError { background-color: #ffcccc; color: black; } |
| 155 | span.resultsWithoutError { background-color: #66ff99; color: black; } |
160 | span.resultsWithoutError { background-color: #66ff99; color: black; } |
| 156 | div.gwCorrect { background-color: #66ff99; color: black; } |
161 | div.gwCorrect { background-color: #66ff99; color: black; } |
| … | |
… | |
| 165 | } |
170 | } |
| 166 | div.gwSoln { |
171 | div.gwSoln { |
| 167 | /* background-color: #e0e0ff; */ |
172 | /* background-color: #e0e0ff; */ |
| 168 | background-color: transparent; |
173 | background-color: transparent; |
| 169 | color: black; |
174 | color: black; |
| 170 | /* padding: 2px; */ |
175 | /* padding: 2px; */, |
| 171 | /* border: dashed black 1px; */ |
176 | /* border: dashed black 1px; */ |
| 172 | } |
177 | } |
| 173 | div.gwSoln b { color: navy; } |
178 | div.gwSoln b { color: navy; } |
| 174 | |
179 | |
| 175 | p.gwPreview { |
180 | p.gwPreview { |
| … | |
… | |
| 193 | background-color: #eeeeee; |
198 | background-color: #eeeeee; |
| 194 | } |
199 | } |
| 195 | |
200 | |
| 196 | </style> |
201 | </style> |
| 197 | <script language="javascript" type="text/javascript"> |
202 | <script language="javascript" type="text/javascript"> |
| 198 | function jumpTo(ref) { |
203 | function jumpTo(ref) { // scrolling javascript functin |
| 199 | if ( ref ) { |
204 | if ( ref ) { |
|
|
205 | var pn = ref - 1; // we start anchors at 1, not zero |
| 200 | if ( navigator.appName == "Netscape" && |
206 | if ( navigator.appName == "Netscape" && |
| 201 | parseFloat(navigator.appVersion) < 5 ) { |
207 | parseFloat(navigator.appVersion) < 5 ) { |
| 202 | var xpos = document.anchors[ref].x; |
208 | var xpos = document.anchors[pn].x; |
| 203 | var ypos = document.anchors[ref].y; |
209 | var ypos = document.anchors[pn].y; |
| 204 | } else { |
210 | } else { |
| 205 | var xpos = document.anchors[ref].offsetLeft; |
211 | var xpos = document.anchors[pn].offsetLeft; |
| 206 | var ypos = document.anchors[ref].offsetTop; |
212 | var ypos = document.anchors[pn].offsetTop; |
| 207 | } |
213 | } |
| 208 | if ( window.scrollTo == null ) { // cover for anyone |
214 | if ( window.scrollTo == null ) { // cover for anyone |
| 209 | window.scroll(xpos,ypos); // lacking js1.2 |
215 | window.scroll(xpos,ypos); // lacking js1.2 |
| 210 | } else { |
216 | } else { |
| 211 | window.scrollTo(xpos,ypos); |
217 | window.scrollTo(xpos,ypos); |
| 212 | } |
218 | } |
| 213 | } |
219 | } |
| 214 | return false; // prevent link from being followed |
220 | return false; // prevent link from being followed |
| 215 | } |
221 | } |
|
|
222 | |
|
|
223 | // timer for gateway |
|
|
224 | var theTime = -1; // -1 before we've initialized |
|
|
225 | |
|
|
226 | function runtimer() { |
|
|
227 | // aesthetically this is displeasing: we're assuming that the |
|
|
228 | // ContentGenerator will put the appropriate form elements in that |
|
|
229 | // page for us to manipulate. even with error checking, it seems sort |
|
|
230 | // of odd. |
|
|
231 | if ( document.gwtimer == null ) { // no timer |
|
|
232 | return; |
|
|
233 | } else { |
|
|
234 | var tm = document.gwtimer.gwtime; |
|
|
235 | var st = document.gwtimer.gwpagetimeleft.value; |
|
|
236 | |
|
|
237 | if ( st == 0 ) { // no time limit |
|
|
238 | return; |
|
|
239 | } else { |
|
|
240 | if ( theTime == -1 ) { |
|
|
241 | theTime = st; |
|
|
242 | tm.value = toMinSec(theTime); |
|
|
243 | setTimeout("runtimer()", 1000); // 1000 ms = 1 sec |
|
|
244 | } else { |
|
|
245 | theTime--; |
|
|
246 | tm.value = toMinSec(theTime); |
|
|
247 | setTimeout("runtimer()", 1000); // 1000 ms = 1 sec |
|
|
248 | } |
|
|
249 | } |
|
|
250 | } |
|
|
251 | } |
|
|
252 | function toMinSec(t) { |
|
|
253 | // convert to min:sec |
|
|
254 | mn = Math.floor(t/60); |
|
|
255 | sc = t - 60*mn; |
|
|
256 | if ( mn < 10 && mn > -1 ) { |
|
|
257 | mn = "0" + mn; |
|
|
258 | } |
|
|
259 | if ( sc < 10 ) { |
|
|
260 | sc = "0" + sc; |
|
|
261 | } |
|
|
262 | return mn + ":" + sc; |
|
|
263 | } |
| 216 | </script> |
264 | </script> |
| 217 | </head> |
265 | </head> |
| 218 | <body> |
266 | <body onload="runtimer();"> |
| 219 | <table width="100%" cellpadding="10" cellspacing="0" border="0"> |
267 | <table width="100%" cellpadding="10" cellspacing="0" border="0"> |
| 220 | <tr valign="top"> |
268 | <tr valign="top"> |
| 221 | <!-- removed left sidebar --> |
269 | <!-- removed left sidebar --> |
| 222 | <!--#if can="info"--> |
270 | <!--#if can="info"--> |
| 223 | <td class="TopPanel" colspan="2"> |
271 | <td class="TopPanel" colspan="2"> |