PageRenderTime 53ms CodeModel.GetById 23ms RepoModel.GetById 0ms app.codeStats 0ms

/pverify3_web.html

https://github.com/terryweaver/webpacs-towers
HTML | 467 lines | 81 code | 18 blank | 368 comment | 0 complexity | 4f44faf6f93201f8ee8bae85e1c3b372 MD5 | raw file
  1. <!--{toplogo}-->
  2. <!--{patron}-->
  3. <!--{logout}-->
  4. <!--{reqmsg}-->
  5. <FORM METHOD=POST onSubmit="return formCheck(this)">
  6. <p>
  7. <!--{iferrmsg}-->
  8. <FONT COLOR=RED SIZE=+2><EM>
  9. <!--{iferrmsgisPIN}-->
  10. <!--{newpinmsg}-->
  11. <!--{else}-->
  12. <!--{errmsg}-->
  13. <!--{xif}-->
  14. </EM></FONT><BR><BR><BR>
  15. <!--{xif}-->
  16. <!--{ifrequestmoney}-->
  17. <FONT SIZE=+1 COLOR=RED>
  18. <!--{requestmoney}-->
  19. </FONT><BR><BR>
  20. <!--{xif}-->
  21. <!--{enterinfo}-->
  22. </p>
  23. <table width="100%" border="0" cellspacing="0" cellpadding="2">
  24. <tr>
  25. <td valign="top" width="1%">
  26. <TABLE>
  27. <!--{ifneedpatronname}-->
  28. <TR><TD WIDTH=1%></TD><TD class="blurb">
  29. <!--{nameexample}-->
  30. </TD></TR><TR><TD class="blurb" width="1%" nowrap>
  31. <!--{nameprompt}-->
  32. </TD><TD>
  33. <!--{name}-->
  34. </TD></TR>
  35. <!--{xif}-->
  36. <!--{ifneedpatronverify}-->
  37. <tr><td colspan="3">&nbsp;</td></tr>
  38. <TR><TD width="1%"></TD><TD class="blurb">
  39. <!--{barcodeexample}-->
  40. </TD></TR>
  41. <TR><TD class="blurb" width="1%" nowrap>
  42. <!--{barcodeprompt}-->
  43. </TD><TD>
  44. <!--{barcode}-->
  45. </TD></TR>
  46. <!--{ifneedspin}-->
  47. <!--{iferrmsgisPIN}-->
  48. <TR><TD COLSPAN=2>
  49. <!--{newpinmsg}-->
  50. </TD></TR><TR><TD class="blurb" width="1%" nowrap>
  51. <!--{pin1prompt}-->
  52. </TD><TD>
  53. <!--{pin1}-->
  54. </TD></TR><TR><TD class="blurb" width="1%" nowrap>
  55. <!--{pin2prompt}-->
  56. </TD><TD>
  57. <!--{pin2}-->
  58. </TD></TR>
  59. <!--{else}-->
  60. <TR><TD></TD><TD class="blurb">
  61. <!--{pininstructions}-->
  62. </TD></TR><TR><TD class="blurb" width="1%" nowrap>
  63. <!--{pinprompt}-->
  64. </TD><TD>
  65. <!--{pin}-->
  66. </TD></TR>
  67. <!--{xif}-->
  68. <!--{xif}-->
  69. <!--{xif}-->
  70. </TABLE>
  71. <P>
  72. <!--{ifcampus}-->
  73. <!--{campus}-->
  74. <!--{else}-->
  75. <!--{holdshelfmenu}-->
  76. <!--{xif}-->
  77. </p>
  78. <!-- checkin block goes here, when (or if) it works-->
  79. <!--{ifreqinst}-->
  80. <P>
  81. <!--{reqinst}-->
  82. <BR>
  83. <!--{inst}-->
  84. <P>
  85. <!--{xif}-->
  86. <!--{ifillreq}-->
  87. <P>
  88. <!--{illreq}-->
  89. </P>
  90. <!--{xif}-->
  91. <!--{ifneedNNA}-->
  92. <P>
  93. <!--{needbyprompt}-->
  94. <!--{needby}-->
  95. <!-- javascript validation code -->
  96. <script language="JavaScript">
  97. <!--
  98. // utility functions for date calculations
  99. function isLeapYear(intYear)
  100. {
  101. if (intYear % 100 == 0)
  102. {
  103. if (intYear % 400 == 0) { return true; }
  104. }
  105. else
  106. {
  107. if ((intYear % 4) == 0) { return true; }
  108. }
  109. return false;
  110. }
  111. function isDayValidForThisMonthAndYear(intDay,intMonth,intYear)
  112. {
  113. if ((intMonth == 4 || intMonth == 6 || intMonth == 9 || intMonth == 11) && intDay > 30 )
  114. {
  115. return false;
  116. }
  117. if (intMonth == 2)
  118. {
  119. if (isLeapYear(intYear))
  120. {
  121. if (intDay > 29)
  122. {
  123. return false;
  124. }
  125. }
  126. else
  127. {
  128. if (intDay > 28)
  129. {
  130. return false;
  131. }
  132. }
  133. }
  134. return true;
  135. }
  136. // form validation function
  137. function formCheck(form)
  138. {
  139. ///////////////////////////////////////////////////////////////////////////////////////
  140. // broswer sniffer
  141. ///////////////////////////////////////////////////////////////////////////////////////
  142. // Ultimate client-side JavaScript client sniff. Version 3.02
  143. // (C) Netscape Communications 1999-2001. Permission granted to reuse and distribute.
  144. // Revised 17 May 99 to add is_nav5up and is_ie5up (see below).
  145. // Revised 20 Dec 00 to add is_gecko and change is_nav5up to is_nav6up
  146. // also added support for IE5.5 Opera4&5 HotJava3 AOLTV
  147. // Revised 22 Feb 01 to correct Javascript Detection for IE 5.x, Opera 4,
  148. // correct Opera 5 detection
  149. // add support for winME and win2k
  150. // synch with browser-type-oo.js
  151. // Revised 26 Mar 01 to correct Opera detection
  152. // Everything you always wanted to know about your JavaScript client
  153. // but were afraid to ask. Creates "is_" variables indicating:
  154. // (1) browser vendor:
  155. // is_nav, is_ie, is_opera, is_hotjava, is_webtv, is_TVNavigator, is_AOLTV
  156. // (2) browser version number:
  157. // is_major (integer indicating major version number: 2, 3, 4 ...)
  158. // is_minor (float indicating full version number: 2.02, 3.01, 4.04 ...)
  159. // (3) browser vendor AND major version number
  160. // is_nav2, is_nav3, is_nav4, is_nav4up, is_nav6, is_nav6up, is_gecko, is_ie3,
  161. // is_ie4, is_ie4up, is_ie5, is_ie5up, is_ie5_5, is_ie5_5up, is_hotjava3, is_hotjava3up,
  162. // is_opera2, is_opera3, is_opera4, is_opera5, is_opera5up
  163. // (4) JavaScript version number:
  164. // is_js (float indicating full JavaScript version number: 1, 1.1, 1.2 ...)
  165. // (5) OS platform and version:
  166. // is_win, is_win16, is_win32, is_win31, is_win95, is_winnt, is_win98, is_winme, is_win2k
  167. // is_os2
  168. // is_mac, is_mac68k, is_macppc
  169. // is_unix
  170. // is_sun, is_sun4, is_sun5, is_suni86
  171. // is_irix, is_irix5, is_irix6
  172. // is_hpux, is_hpux9, is_hpux10
  173. // is_aix, is_aix1, is_aix2, is_aix3, is_aix4
  174. // is_linux, is_sco, is_unixware, is_mpras, is_reliant
  175. // is_dec, is_sinix, is_freebsd, is_bsd
  176. // is_vms
  177. //
  178. // See http://www.it97.de/JavaScript/JS_tutorial/bstat/navobj.html and
  179. // http://www.it97.de/JavaScript/JS_tutorial/bstat/Browseraol.html
  180. // for detailed lists of userAgent strings.
  181. //
  182. // Note: you don't want your Nav4 or IE4 code to "turn off" or
  183. // stop working when new versions of browsers are released, so
  184. // in conditional code forks, use is_ie5up ("IE 5.0 or greater")
  185. // is_opera5up ("Opera 5.0 or greater") instead of is_ie5 or is_opera5
  186. // to check version in code which you want to work on future
  187. // versions.
  188. // convert all characters to lowercase to simplify testing
  189. var agt=navigator.userAgent.toLowerCase();
  190. // *** BROWSER VERSION ***
  191. // Note: On IE5, these return 4, so use is_ie5up to detect IE5.
  192. var is_major = parseInt(navigator.appVersion);
  193. var is_minor = parseFloat(navigator.appVersion);
  194. // Note: Opera and WebTV spoof Navigator. We do strict client detection.
  195. // If you want to allow spoofing, take out the tests for opera and webtv.
  196. var is_nav = ((agt.indexOf('mozilla')!=-1) && (agt.indexOf('spoofer')==-1)
  197. && (agt.indexOf('compatible') == -1) && (agt.indexOf('opera')==-1)
  198. && (agt.indexOf('webtv')==-1) && (agt.indexOf('hotjava')==-1));
  199. var is_nav2 = (is_nav && (is_major == 2));
  200. var is_nav3 = (is_nav && (is_major == 3));
  201. var is_nav4 = (is_nav && (is_major == 4));
  202. var is_nav4up = (is_nav && (is_major >= 4));
  203. var is_navonly = (is_nav && ((agt.indexOf(";nav") != -1) ||
  204. (agt.indexOf("; nav") != -1)) );
  205. var is_nav6 = (is_nav && (is_major == 5));
  206. var is_nav6up = (is_nav && (is_major >= 5));
  207. var is_gecko = (agt.indexOf('gecko') != -1);
  208. var is_ie = ((agt.indexOf("msie") != -1) && (agt.indexOf("opera") == -1));
  209. var is_ie3 = (is_ie && (is_major < 4));
  210. var is_ie4 = (is_ie && (is_major == 4) && (agt.indexOf("msie 5")==-1) );
  211. var is_ie4up = (is_ie && (is_major >= 4));
  212. var is_ie5 = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.0")!=-1) );
  213. var is_ie5_5 = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.5") !=-1));
  214. var is_ie5up = (is_ie && !is_ie3 && !is_ie4);
  215. var is_ie5_5up =(is_ie && !is_ie3 && !is_ie4 && !is_ie5);
  216. // KNOWN BUG: On AOL4, returns false if IE3 is embedded browser
  217. // or if this is the first browser window opened. Thus the
  218. // variables is_aol, is_aol3, and is_aol4 aren't 100% reliable.
  219. var is_aol = (agt.indexOf("aol") != -1);
  220. var is_aol3 = (is_aol && is_ie3);
  221. var is_aol4 = (is_aol && is_ie4);
  222. var is_aol5 = (agt.indexOf("aol 5") != -1);
  223. var is_aol6 = (agt.indexOf("aol 6") != -1);
  224. var is_opera = (agt.indexOf("opera") != -1);
  225. var is_opera2 = (agt.indexOf("opera 2") != -1 || agt.indexOf("opera/2") != -1);
  226. var is_opera3 = (agt.indexOf("opera 3") != -1 || agt.indexOf("opera/3") != -1);
  227. var is_opera4 = (agt.indexOf("opera 4") != -1 || agt.indexOf("opera/4") != -1);
  228. var is_opera5 = (agt.indexOf("opera 5") != -1 || agt.indexOf("opera/5") != -1);
  229. var is_opera5up = (is_opera && !is_opera2 && !is_opera3 && !is_opera4);
  230. var is_webtv = (agt.indexOf("webtv") != -1);
  231. var is_TVNavigator = ((agt.indexOf("navio") != -1) || (agt.indexOf("navio_aoltv") != -1));
  232. var is_AOLTV = is_TVNavigator;
  233. var is_hotjava = (agt.indexOf("hotjava") != -1);
  234. var is_hotjava3 = (is_hotjava && (is_major == 3));
  235. var is_hotjava3up = (is_hotjava && (is_major >= 3));
  236. // *** JAVASCRIPT VERSION CHECK ***
  237. var is_js;
  238. if (is_nav2 || is_ie3) is_js = 1.0;
  239. else if (is_nav3) is_js = 1.1;
  240. else if (is_opera5up) is_js = 1.3;
  241. else if (is_opera) is_js = 1.1;
  242. else if ((is_nav4 && (is_minor <= 4.05)) || is_ie4) is_js = 1.2;
  243. else if ((is_nav4 && (is_minor > 4.05)) || is_ie5) is_js = 1.3;
  244. else if (is_hotjava3up) is_js = 1.4;
  245. else if (is_nav6 || is_gecko) is_js = 1.5;
  246. // NOTE: In the future, update this code when newer versions of JS
  247. // are released. For now, we try to provide some upward compatibility
  248. // so that future versions of Nav and IE will show they are at
  249. // *least* JS 1.x capable. Always check for JS version compatibility
  250. // with > or >=.
  251. else if (is_nav6up) is_js = 1.5;
  252. // NOTE: ie5up on mac is 1.4
  253. else if (is_ie5up) is_js = 1.3
  254. // HACK: no idea for other browsers; always check for JS version with > or >=
  255. else is_js = 0.0;
  256. // *** PLATFORM ***
  257. var is_win = ( (agt.indexOf("win")!=-1) || (agt.indexOf("16bit")!=-1) );
  258. // NOTE: On Opera 3.0, the userAgent string includes "Windows 95/NT4" on all
  259. // Win32, so you can't distinguish between Win95 and WinNT.
  260. var is_win95 = ((agt.indexOf("win95")!=-1) || (agt.indexOf("windows 95")!=-1));
  261. // is this a 16 bit compiled version?
  262. var is_win16 = ((agt.indexOf("win16")!=-1) ||
  263. (agt.indexOf("16bit")!=-1) || (agt.indexOf("windows 3.1")!=-1) ||
  264. (agt.indexOf("windows 16-bit")!=-1) );
  265. var is_win31 = ((agt.indexOf("windows 3.1")!=-1) || (agt.indexOf("win16")!=-1) ||
  266. (agt.indexOf("windows 16-bit")!=-1));
  267. var is_winme = ((agt.indexOf("win 9x 4.90")!=-1));
  268. var is_win2k = ((agt.indexOf("windows nt 5.0")!=-1));
  269. // NOTE: Reliable detection of Win98 may not be possible. It appears that:
  270. // - On Nav 4.x and before you'll get plain "Windows" in userAgent.
  271. // - On Mercury client, the 32-bit version will return "Win98", but
  272. // the 16-bit version running on Win98 will still return "Win95".
  273. var is_win98 = ((agt.indexOf("win98")!=-1) || (agt.indexOf("windows 98")!=-1));
  274. var is_winnt = ((agt.indexOf("winnt")!=-1) || (agt.indexOf("windows nt")!=-1));
  275. var is_win32 = (is_win95 || is_winnt || is_win98 ||
  276. ((is_major >= 4) && (navigator.platform == "Win32")) ||
  277. (agt.indexOf("win32")!=-1) || (agt.indexOf("32bit")!=-1));
  278. var is_os2 = ((agt.indexOf("os/2")!=-1) ||
  279. (navigator.appVersion.indexOf("OS/2")!=-1) ||
  280. (agt.indexOf("ibm-webexplorer")!=-1));
  281. var is_mac = (agt.indexOf("mac")!=-1);
  282. // hack ie5 js version for mac
  283. if (is_mac && is_ie5up) is_js = 1.4;
  284. var is_mac68k = (is_mac && ((agt.indexOf("68k")!=-1) ||
  285. (agt.indexOf("68000")!=-1)));
  286. var is_macppc = (is_mac && ((agt.indexOf("ppc")!=-1) ||
  287. (agt.indexOf("powerpc")!=-1)));
  288. var is_sun = (agt.indexOf("sunos")!=-1);
  289. var is_sun4 = (agt.indexOf("sunos 4")!=-1);
  290. var is_sun5 = (agt.indexOf("sunos 5")!=-1);
  291. var is_suni86= (is_sun && (agt.indexOf("i86")!=-1));
  292. var is_irix = (agt.indexOf("irix") !=-1); // SGI
  293. var is_irix5 = (agt.indexOf("irix 5") !=-1);
  294. var is_irix6 = ((agt.indexOf("irix 6") !=-1) || (agt.indexOf("irix6") !=-1));
  295. var is_hpux = (agt.indexOf("hp-ux")!=-1);
  296. var is_hpux9 = (is_hpux && (agt.indexOf("09.")!=-1));
  297. var is_hpux10= (is_hpux && (agt.indexOf("10.")!=-1));
  298. var is_aix = (agt.indexOf("aix") !=-1); // IBM
  299. var is_aix1 = (agt.indexOf("aix 1") !=-1);
  300. var is_aix2 = (agt.indexOf("aix 2") !=-1);
  301. var is_aix3 = (agt.indexOf("aix 3") !=-1);
  302. var is_aix4 = (agt.indexOf("aix 4") !=-1);
  303. var is_linux = (agt.indexOf("inux")!=-1);
  304. var is_sco = (agt.indexOf("sco")!=-1) || (agt.indexOf("unix_sv")!=-1);
  305. var is_unixware = (agt.indexOf("unix_system_v")!=-1);
  306. var is_mpras = (agt.indexOf("ncr")!=-1);
  307. var is_reliant = (agt.indexOf("reliantunix")!=-1);
  308. var is_dec = ((agt.indexOf("dec")!=-1) || (agt.indexOf("osf1")!=-1) ||
  309. (agt.indexOf("dec_alpha")!=-1) || (agt.indexOf("alphaserver")!=-1) ||
  310. (agt.indexOf("ultrix")!=-1) || (agt.indexOf("alphastation")!=-1));
  311. var is_sinix = (agt.indexOf("sinix")!=-1);
  312. var is_freebsd = (agt.indexOf("freebsd")!=-1);
  313. var is_bsd = (agt.indexOf("bsd")!=-1);
  314. var is_unix = ((agt.indexOf("x11")!=-1) || is_sun || is_irix || is_hpux ||
  315. is_sco ||is_unixware || is_mpras || is_reliant ||
  316. is_dec || is_sinix || is_aix || is_linux || is_bsd || is_freebsd);
  317. var is_vms = ((agt.indexOf("vax")!=-1) || (agt.indexOf("openvms")!=-1));
  318. ///////////////////////////////////////////////////////////////////////////////////////
  319. // begin form validation
  320. ///////////////////////////////////////////////////////////////////////////////////////
  321. // if this client is running an unusable version of JavaScript, skip this validation
  322. if (is_js < 1.1)
  323. {
  324. return true;
  325. }
  326. // read in values from the form
  327. var strSuppliedYear = form.needby_Year.options[form.needby_Year.selectedIndex].text;
  328. var strSuppliedMonth = form.needby_Month.options[form.needby_Month.selectedIndex].text;
  329. var strSuppliedDay = form.needby_Day.options[form.needby_Day.selectedIndex].text;
  330. // convert supplied date strings to IETF date format
  331. var strSuppliedDate = "" + strSuppliedDay + " " + strSuppliedMonth + " " + strSuppliedYear + " 00:00:00 CST";
  332. // get today's date in GMTmilliseconds format
  333. var Today = new Date();
  334. // convert supplied date to GMTmilliseconds format
  335. var SuppliedDate = new Date(strSuppliedDate);
  336. // if the resulting date object is not a number, the user hasn't picked a date. skip validation.
  337. if (isNaN(SuppliedDate))
  338. {
  339. return true;
  340. }
  341. // Compare Today to SuppliedDate
  342. // If SuppliedDate is less than Today, alert the user, and return false
  343. if (SuppliedDate <= Today)
  344. {
  345. alert("INVALID NCEL BY DATE: please supply a 'cancel by' date that occurs in the future.");
  346. return false;
  347. }
  348. // check to see if the supplied day value is valid for the supplied month and year
  349. if (!isDayValidForThisMonthAndYear(parseInt(strSuppliedDay), form.needby_Month.selectedIndex, parseInt(strSuppliedYear)))
  350. {
  351. alert("INVALID NCEL BY DATE: are you sure there are " + strSuppliedDay + " days in " + strSuppliedMonth + "?");
  352. return false;
  353. }
  354. // if we made it this far, the date must be good
  355. return true;
  356. }
  357. //-->;
  358. </script>
  359. </p>
  360. <!--{else}-->
  361. <!-- passthrough javascript code -->
  362. <script language="JavaScript">
  363. <!--
  364. function formCheck(form) {
  365. return true;
  366. }
  367. //-->;
  368. </script>
  369. <!--{xif}-->
  370. <br>
  371. <!--{submit}-->
  372. </td>
  373. <td valign="top" align="right">
  374. <table width="200" border="0" cellspacing="0" cellpadding="2" bgcolor="#FFCC99">
  375. <tr>
  376. <td>
  377. <p><b><font size="-1" face="Arial, Helvetica, sans-serif">Campus ID Help</font></b></p>
  378. <p class="blurb"><font size="-2" face="Arial, Helvetica, sans-serif">
  379. &middot; Conception Abbey - <b>CA</b><br>
  380. &middot; Missouri Western State University - <b>MW</b><br>
  381. &middot; North Central Missouri College - <b>NCMC</b><br>
  382. &middot; Northwest Missouri State University - <b>NW</b></font></p>
  383. <p class="blurb"><font size="-2" face="Arial, Helvetica, sans-serif">
  384. &nbsp;&nbsp;&nbsp; Type your ID number (dashes are not necessary) plus your institution code.
  385. <br>&nbsp;&nbsp;&nbsp; For example: <tt><font size="-1" color="#CC0000">999999999NCMC</font></tt> would be a Campus
  386. ID for a student at North Central Missouri College.<br><br></font></p>
  387. <p class="blurb"><font size="-1" face="Arial, Helvetica, sans-serif"><b><u>NORTHWEST PATRONS</u><br>
  388. <b>Use ID number listed on<br>
  389. university ID card. Phone<br>
  390. 660-562-1193 for assistance.</b></p>
  391. </td>
  392. </tr>
  393. </table>
  394. </td>
  395. </tr>
  396. </table>
  397. <P>
  398. </FORM>
  399. <TABLE WIDTH=100%>
  400. <TR><TD>
  401. <!--{startover}-->
  402. </TD></TR>
  403. </TABLE>
  404. <!--{botlogo}-->
  405. </BODY>
  406. </HTML>