Count Lines in Pages

Contents of Page: picks2_old.asp Number of Lines: 315 Last Modified: 8/22/2018 1:33:05 PM
0001: <% @Language = "VBScript" %>
0002: 
0003: <!-- #include FILE="include/adovbs.inc" -->
0004: <!-- #include FILE="include/constants.inc" -->
0005: <!-- #include FILE="include/funcs.asp" -->
0006: 
0007: <%
0008: 	user = Request.Cookies("user")
0009: 	If user = ""  Or (user <> "" And Session("loggedIn") = "") Then Response.Redirect("login.asp?from=picks.asp")
0010: 
0011: 	lineColor = "#cccccc"
0012: 
0013: 	' get data
0014: 	Set rsFinal = Server.CreateObject("ADODB.Recordset")
0015: 	sqlString = "SELECT * FROM mmFinals " & _
0016: 			"WHERE Season = " & season
0017: 	rsFinal.Open sqlString, conn, adOpenStatic, adLockReadOnly, adCmdText
0018: 	finalVenue = rsFinal("FinalVenue").Value
0019: 	finalDate = rsFinal("FinalDate").Value
0020: 	semiFinal1Venue = rsFinal("SemiFinal1Venue").Value
0021: 	semiFinal1Date = rsFinal("SemiFinal1Date").Value
0022: 	semiFinal2Venue = rsFinal("SemiFinal2Venue").Value
0023: 	semiFinal2Date = rsFinal("SemiFinal2Date").Value
0024: 	rsFinal.Close
0025: 	Set rsFinal = Nothing
0026: 
0027: 	Set rsPicks = Server.CreateObject("ADODB.Recordset")
0028: 	sqlString = "SELECT A15, B15, C15, D15 FROM mmPicks " & _
0029: 			"WHERE Season = " & season & " "  & _
0030: 			"AND EmailAddress = '" & user & "' " & _
0031: 			"AND Complete = 'No'"
0032: 	rsPicks.Open sqlString, conn, adOpenStatic, adLockReadOnly, adCmdText
0033: 	A15 = rsPicks("A15").Value
0034: 	B15 = rsPicks("B15").Value
0035: 	C15 = rsPicks("C15").Value
0036: 	D15 = rsPicks("D15").Value
0037: 	rsPicks.Close
0038: 	Set rsPicks = Nothing
0039: 
0040: 	Set rsEntry = Server.CreateObject("ADODB.Recordset")
0041: 	sqlString = "SELECT Name, FirstName FROM mmEntries " & _
0042: 			"WHERE Season = " & season & " "  & _
0043: 			"AND EmailAddress = '" & user & "' "  
0044: 	rsEntry.Open sqlString, conn, adOpenStatic, adLockReadOnly, adCmdText
0045: 	lastName = rsEntry("Name").Value
0046: 	firstName = rsEntry("FirstName").Value
0047: 	rsEntry.Close
0048: 	Set rsEntry = Nothing
0049: 	entry = firstName & " " & lastName
0050: %>
0051: 
0052: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
0053: 
0054: <html>
0055: <head>
0056: <title>March Madness - Final Picks</title>
0057: 	<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
0058: 	<link href="mm.css" rel="stylesheet" type="text/css">
0059: 	<script language="JavaScript">
0060: 
0061: 		var finalist = new Array();
0062: 		finalist[1] = "<%= A15 %>";
0063: 		finalist[2] = "<%= B15 %>";
0064: 		finalist[3] = "<%= C15 %>";
0065: 		finalist[4] = "<%= D15 %>";
0066: 
0067: 		function rSelect(game)	{
0068: 			var form = document.finalpicks;
0069: 			if (game == "semi1")	{
0070: 				form.semi1.style.backgroundColor = "#e8e8e8";
0071: 				form.semi2.style.backgroundColor = "";
0072: 				form.final1.style.backgroundColor = "";
0073: 				form.final2.style.backgroundColor = "";
0074: 				form.champion.style.backgroundColor = "";
0075: 				form.semi1.blur();
0076: 				form.final1.value = form.semi1.value;
0077: 				form.S1.value = finalist[1];
0078: 				form.champion.value = '';
0079: 			}
0080: 			if (game == "semi2")	{
0081: 				form.semi1.style.backgroundColor = "";
0082: 				form.semi2.style.backgroundColor = "#e8e8e8";
0083: 				form.final1.style.backgroundColor = "";
0084: 				form.final2.style.backgroundColor = "";
0085: 				form.champion.style.backgroundColor = "";
0086: 				form.semi2.blur();
0087: 				form.final1.value = form.semi2.value;
0088: 				form.S1.value = finalist[2];
0089: 				form.champion.value = '';
0090: 			}
0091: 			if (game == "semi3")	{
0092: 				form.semi3.style.backgroundColor = "#e8e8e8";
0093: 				form.semi4.style.backgroundColor = "";
0094: 				form.final1.style.backgroundColor = "";
0095: 				form.final2.style.backgroundColor = "";
0096: 				form.champion.style.backgroundColor = "";
0097: 				form.semi3.blur();
0098: 				form.final2.value = form.semi3.value;
0099: 				form.S2.value = finalist[3];
0100: 				form.champion.value = '';
0101: 			}
0102: 			if (game == "semi4")	{
0103: 				form.semi3.style.backgroundColor = "";
0104: 				form.semi4.style.backgroundColor = "#e8e8e8";
0105: 				form.final1.style.backgroundColor = "";
0106: 				form.final2.style.backgroundColor = "";
0107: 				form.champion.style.backgroundColor = "";
0108: 				form.semi4.blur();
0109: 				form.final2.value = form.semi4.value;
0110: 				form.S2.value = finalist[4];
0111: 				form.champion.value = '';
0112: 			}
0113: 			if (game == "final1")	{
0114: 				form.final1.style.backgroundColor = "";
0115: 				form.final2.style.backgroundColor = "";
0116: 				form.champion.style.backgroundColor = "#FED87B";
0117: 				form.final1.blur();
0118: 				form.champion.value = form.final1.value;
0119: 				form.F1.value = form.S1.value;
0120: 			}
0121: 			if (game == "final2")	{
0122: 				form.final1.style.backgroundColor = "";
0123: 				form.final2.style.backgroundColor = "";
0124: 				form.champion.style.backgroundColor = "#FED87B";
0125: 				form.final2.blur();
0126: 				form.champion.value = form.final2.value;
0127: 				form.F1.value = form.S2.value;
0128: 			}
0129: 		}
0130: 		
0131: 		function checkSel()	{
0132: 			var form = document.finalpicks;
0133: 			if (form.entryname.value == "")	{
0134: 				alert("Please entry a name for your team");
0135: 				form.entryname.select();
0136: 				return false;
0137: 			}
0138: 			for (i = 0; i < form.elements.length; i++)	{
0139: 				if (form.elements[i].type == "hidden" && form.elements[i].value == "")	{
0140: 					alert("Please select all the winners before submitting picks");
0141: 					return false;
0142: 				}
0143: 			}
0144: 			return true;		
0145: 		}
0146: 		
0147: 	</script>
0148: </head>
0149: 
0150: <body bgcolor="#ffffff" onload="document.finalpicks.entryname.select()">
0151: 
0152: <form name="finalpicks" method="post" action="picks_saveFinal.asp" onsubmit="return checkSel()">	
0153: 	<table width="572" border="0" cellpadding="0" cellspacing="0" align="center">
0154: 		<tr><td align="center" colspan="13" class="bigblue"><%= season %> NCAA Division I Men's Basketball Championship</td></tr>
0155: 		<tr><td align="center" colspan="13" class="medbold"><%= finalVenue %> - <%= finalDate %></td></tr>
0156: 		<tr><td align="center" colspan="13" class="space">&nbsp;</td></tr>
0157: 		<tr>
0158: 			<td class="normbold" align="right" colspan="6">Entry Name&nbsp;:&nbsp;&nbsp;</td>
0159: 			<td class="norm" align="left" colspan="7">
0160: 				<input type="text" name="entryname" value="<%= entry %>" class="norm">	
0161: 			</td>
0162: 		</tr>
0163: 		<tr>
0164: 			<td width="150" align="center" class="normbold"><%= displayRegion(1) %></td>
0165: 			<td width="5"><img src="images/clear.gif" height="1" width="1"></td>
0166: 			<td width="1"><img src="images/clear.gif" height="1" width="1"></td>
0167: 			<td width="5"><img src="images/clear.gif" height="1" width="1"></td>
0168: 			<td width="50" class="normbold">&nbsp;</td>
0169: 			<td width="50" class="normbold">&nbsp;</td>
0170: 			<td width="50" class="normbold">&nbsp;</td>
0171: 			<td width="50" class="normbold">&nbsp;</td>
0172: 			<td width="50" class="normbold">&nbsp;</td>
0173: 			<td width="5"><img src="images/clear.gif" height="1" width="1"></td>
0174: 			<td width="1"><img src="images/clear.gif" height="1" width="1"></td>
0175: 			<td width="5"><img src="images/clear.gif" height="1" width="1"></td>
0176: 			<td width="150" align="center" class="normbold"><%= displayRegion(3) %></td>
0177: 		</tr>
0178: 		<tr>
0179: 			<td rowspan="3">
0180: 				<input type="text" name="semi1" value="<%= displayTeam(A15) %>" style="text-align:center;width:150;" onFocus="rSelect('semi1')">
0181: 			</td>
0182: 			<td colspan="11">&nbsp;</td>
0183: 			<td rowspan="3">
0184: 				<input type="text" name="semi3" value="<%= displayTeam(C15) %>" style="text-align:center;width:150;" onFocus="rSelect('semi3')">
0185: 			</td>
0186: 		</tr>
0187: 		<tr>
0188: 			<td height="1" bgcolor="<%= linecolor %>"><img src="images/clear.gif" height="1" width="1"></td>
0189: 			<td rowspan="15" bgcolor="<%= linecolor %>"><img src="images/clear.gif" height="1" width="1"></td>
0190: 			<td colspan="7"><img src="images/clear.gif" height="1" width="1"></td>
0191: 			<td rowspan="15" bgcolor="<%= linecolor %>"><img src="images/clear.gif" height="1" width="1"></td>
0192: 			<td bgcolor="<%= linecolor %>"><img src="images/clear.gif" height="1" width="1"></td>
0193: 		</tr>
0194: 		<tr>
0195: 			<td>&nbsp;</td>
0196: 			<td colspan="7">&nbsp;</td>
0197: 			<td>&nbsp;</td>
0198: 		</tr>
0199: 		<tr>
0200: 			<td colspan="2">&nbsp;</td>
0201: 			<td>&nbsp;</td>
0202: 			<td rowspan="3" colspan="3">
0203: 				<input type="hidden" name="S1" value="">
0204: 				<input type="text" name="final1" value="" style="text-align:center;width:150;" onFocus="rSelect('final1')">
0205: 			</td>
0206: 			<td colspan="3">&nbsp;</td>
0207: 			<td colspan="2">&nbsp;</td>
0208: 		</tr>
0209: 		<tr>
0210: 			<td height="1" colspan="2"><img src="images/clear.gif" height="1" width="1"></td>
0211: 			<td bgcolor="<%= linecolor %>"><img src="images/clear.gif" height="1" width="1"></td>
0212: 			<td colspan="3"><img src="images/clear.gif" height="1" width="1"></td>
0213: 			<td colspan="2"><img src="images/clear.gif" height="1" width="1"></td>
0214: 		</tr>
0215: 		<tr>
0216: 			<td colspan="2">&nbsp;</td>
0217: 			<td>&nbsp;</td>
0218: 			<td colspan="3">&nbsp;</td>
0219: 			<td colspan="2">&nbsp;</td>
0220: 		</tr>
0221: 		<tr>
0222: 			<td align="center" class="normbold">Semifinal</td>
0223: 			<td>&nbsp;</td>
0224: 			<td colspan="7">&nbsp;</td>
0225: 			<td>&nbsp;</td>
0226: 			<td align="center" class="normbold">Semifinal</td>
0227: 		</tr>
0228: 		<tr>
0229: 			<td align="center" class="normbold"><%= semiFinal1Venue %></td>
0230: 			<td>&nbsp;</td>
0231: 			<td colspan="2">&nbsp;</td>
0232: 			<td colspan="3" align="center" class="normbold">National Champion</td>
0233: 			<td colspan="2">&nbsp;</td>
0234: 			<td>&nbsp;</td>
0235: 			<td align="center" class="normbold"><%= semiFinal2Venue %></td>
0236: 		</tr>
0237: 		<tr>
0238: 			<td align="center" class="normbold"><%= semiFinal1Date %></td>
0239: 			<td>&nbsp;</td>
0240: 			<td colspan="2">&nbsp;</td>
0241: 			<td colspan="3">
0242: 				<input type="hidden" name="F1" value="">
0243: 				<input type="text" name="champion" value="" style="text-align:center;width:150;" onFocus="this.blur()">
0244: 			</td>
0245: 			<td colspan="2">&nbsp;</td>
0246: 			<td>&nbsp;</td>
0247: 			<td align="center" class="normbold"><%= semiFinal2Date %></td>
0248: 		</tr>
0249: 		<tr>
0250: 			<td colspan="2">&nbsp;</td>
0251: 			<td colspan="7">&nbsp;</td>
0252: 			<td colspan="2">&nbsp;</td>
0253: 		</tr>
0254: 		<tr>
0255: 			<td colspan="2">&nbsp;</td>
0256: 			<td colspan="7">&nbsp;</td>
0257: 			<td colspan="2">&nbsp;</td>
0258: 		</tr>
0259: 		<tr>
0260: 			<td colspan="2">&nbsp;</td>
0261: 			<td colspan="3">&nbsp;</td>
0262: 			<td colspan="3" rowspan="3">
0263: 				<input type="hidden" name="S2" value="">
0264: 				<input type="text" name="final2" value="" style="text-align:center;width:150;" onFocus="rSelect('final2')">
0265: 			</td>
0266: 			<td>&nbsp;</td>
0267: 			<td colspan="2">&nbsp;</td>
0268: 		</tr>
0269: 		<tr>
0270: 			<td height="1" colspan="2"><img src="images/clear.gif" height="1" width="1"></td>
0271: 			<td colspan="3"><img src="images/clear.gif" height="1" width="1"></td>
0272: 			<td bgcolor="<%= linecolor %>"><img src="images/clear.gif" height="1" width="1"></td>
0273: 			<td colspan="2"><img src="images/clear.gif" height="1" width="1"></td>
0274: 		</tr>
0275: 		<tr>
0276: 			<td align="center" class="normbold"><%= displayRegion(2) %></td>
0277: 			<td>&nbsp;</td>
0278: 			<td colspan="3">&nbsp;</td>
0279: 			<td>&nbsp;</td>
0280: 			<td>&nbsp;</td>
0281: 			<td align="center" class="normbold"><%= displayRegion(4) %></td>
0282: 		</tr>
0283: 		<tr>
0284: 			<td rowspan="3">
0285: 				<input type="text" name="semi2" value="<%= displayTeam(B15) %>" style="text-align:center;width:150;" onFocus="rSelect('semi2')">
0286: 			</td>
0287: 			<td>&nbsp;</td>
0288: 			<td colspan="7">&nbsp;</td>
0289: 			<td>&nbsp;</td>
0290: 			<td rowspan="3">
0291: 				<input type="text" name="semi4" value="<%= displayTeam(D15) %>" style="text-align:center;width:150;" onFocus="rSelect('semi4')">
0292: 			</td>
0293: 		</tr>
0294: 		<tr>
0295: 			<td height="1" bgcolor="<%= linecolor %>"><img src="images/clear.gif" height="1" width="1"></td>
0296: 			<td colspan="7"><img src="images/clear.gif" height="1" width="1"></td>
0297: 			<td bgcolor="<%= linecolor %>"><img src="images/clear.gif" height="1" width="1"></td>
0298: 		</tr>
0299: 		<tr>
0300: 			<td colspan="11">&nbsp;</td>
0301: 		</tr>
0302: 
0303: 		<tr><td colspan="13">&nbsp;</td></tr>
0304: 
0305: 		<tr>
0306: 			<td colspan="13" class="norm" align="center">
0307: 				<input type="Submit" value="Submit Picks" class="norm">
0308: 			</td>
0309: 		</tr>
0310: 
0311: 	</table>
0312: </form>
0313: 
0314: </body>
0315: </html>