Count Lines in Pages

Contents of Page: mmEntriesUpdate.asp Number of Lines: 262 Last Modified: 3/7/2026 9:32:38 AM
0001: <%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
0002: <!-- #include FILE="include/adovbs.inc" -->
0003: <!-- #include FILE="include/constants.inc" -->
0004: <!-- #include FILE="include/funcs.asp" -->
0005: <%
0006: 	from = Request.QueryString("from")
0007:   	Deadbeat = Request.QueryString("DB") 
0008: 	
0009: 	ReturnPage = Session("ReturnPage")
0010:   		
0011: 	action = Trim(Request.Form("action"))
0012: 	ID = Trim(Request.Form("ID"))
0013: 	Name = Trim(Request.Form("Name"))
0014:         EmailAddress = Trim(Request.Form("EmailAddress"))
0015:         TextEmailAddress = Trim(Request.Form("TextEmailAddress"))
0016:         Password = Trim(Request.Form("Password"))
0017:         FirstName = Trim(Request.Form("FirstName"))
0018:        Address = Trim(Request.Form("Address"))
0019:         City = Trim(Request.Form("City"))
0020:         RefBy = Trim(Request.Form("RefBy"))        
0021:        State = Trim(Request.Form("State"))
0022:        Zip = Trim(Request.Form("Zip"))
0023:        Group = Trim(Request.Form("Group"))
0024:        Group2 = Trim(Request.Form("Group2"))   
0025: 
0026: If Group2 = "" Then
0027: Group2 = "DEFAULT"
0028: End If       
0029:            Group3 = Trim(Request.Form("Group3"))   
0030: If Group3 = "" Then
0031: Group3 = "DEFAULT"
0032: End If 
0033:         Entries = Trim(Request.Form("Entries"))
0034:         FreeEntries = Trim(Request.Form("FreeEntries"))
0035:         TotalRefs = Trim(Request.Form("TotalRefs"))        
0036: 	    PaidEntries = Trim(Request.Form("Paid"))
0037:         Entries2nd = Trim(Request.Form("Entries2nd"))
0038: 	    Paid2nd = Trim(Request.Form("Paid2nd"))
0039: 	    AllPaidUp = Trim(Request.Form("AllPaidUp"))
0040: 		EmailIt = Trim(Request.Form("EmailChgs"))
0041: 		Email2ndIt = Trim(Request.Form("Email2ndChgs"))
0042: 		EMailMakePicks = Trim(Request.Form("EmailMakePicks"))
0043: 		ShowStand = Trim(Request.Form("ShowStand"))	
0044: 		PayPalUsed = Trim(Request.Form("PayPalUsed"))	
0045: 		CashUsed = Trim(Request.Form("CashUsed"))
0046: 		VenMoUsed = Trim(Request.Form("VenMoUsed"))
0047: 		VenMo = Trim(Request.Form("VenMo"))
0048: 		Zelle = Trim(Request.Form("Zelle"))		
0049: 		ZelleUsed = Trim(Request.Form("ZelleUsed"))
0050: 		PayPalEmailAddress = Trim(Request.Form("PayPalEmailAddress"))		
0051: 		AmountDonatedToCOH = Trim(Request.Form("AmountDonatedToCOH"))	
0052: 		If AmountDonatedToCOH = "" Then
0053: 			 AmountDonatedToCOH = 0
0054: 		End If
0055: 		If AllPaidUp = "Y" Then
0056: 		PaidEntries = Entries
0057: 		End If
0058: 
0059: 	If numEntries = "" Then
0060: 	numEntries = 0
0061: 	End If
0062: 	If Entries2nd = "" Then
0063: 	Entries2nd = 0
0064: 	End If	
0065: 	If PaidEntries = "" Then
0066: 	PaidEntries = 0
0067: 	End If
0068: 	If Paid2nd = "" Then
0069: 	Paid2nd = 0
0070: 	End If					
0071: '	If action = "Add" Then
0072: '	Set rs = Server.CreateObject("ADODB.Recordset")
0073: '		rs.Open "mmEntries", Conn, adOpenDynamic, adLockOptimistic, adCmdTable
0074: '		rs.AddNew
0075: '	ElseIf action = "Update" Then
0076: 		Set rs = Server.CreateObject("ADODB.Recordset")
0077: 		sqlString = "SELECT * FROM mmEntries WHERE ID = " & ID
0078: 		rs.Open sqlString, Conn, adOpenDynamic, adLockOptimistic, adCmdText
0079: 		If rs.EOF Then
0080: 			rs.Close
0081: 			Response.Redirect("whoisin.asp")
0082: 		End If
0083: '	Else
0084: '		Response.Redirect("whoisin.asp")
0085: '	End If
0086: 'response.write(ID & "=")
0087: 'response.write(EmailIt & "=")	
0088: 
0089: response.write(sqlString)
0090: 'response.write(PaidEntries)
0091: '	rs("ID").Value = ID
0092: 	RegNumber = rs("RegNumber").Value
0093: 	rs("Name").Value = Name
0094: 	rs("FirstName").Value = FirstName
0095: 	rs("EmailAddress").Value = EmailAddress
0096: 	rs("TextEmailAddress").Value = TextEmailAddress
0097: 	rs("Password").Value = Password
0098: 	rs("Address").Value = Address
0099: 	rs("City").Value = City
0100: 	rs("State").Value = State
0101: 	rs("Zip").Value = Zip
0102: 	rs("RefBy").Value = RefBy	
0103: '	rs("GroupName").Value = Group	
0104: '	rs("GroupName2").Value = Group2	
0105: '	rs("GroupName3").Value = Group3		
0106: 	rs("numEntries").Value = Entries
0107: 	rs("FreeEntries").Value = FreeEntries
0108: 	rs("TotalRefs").Value = 0
0109: 	rs("PaidEntries").Value = PaidEntries
0110: 	rs("num2ndEntries").Value = Entries2nd
0111: 	rs("Paid2ndEntries").Value = Paid2nd	
0112: 	rs("AmountDonatedToCOH").Value = AmountDonatedToCOH
0113: 	If ShowStand <> "" Then
0114: 	rs("ShowStandings").Value = True
0115: 	Else
0116: 	rs("ShowStandings").Value = False
0117: 	End If
0118: 	If PayPalUsed <> "" Then
0119: 	rs("PayPalUsed").Value = True
0120: 	Else
0121: 	rs("PayPalUsed").Value = False
0122: 	End If	
0123: 	If CashUsed <> "" Then
0124: 	rs("CashUsed").Value = True
0125: 	Else
0126: 	rs("CashUsed").Value = False
0127: 	End If	
0128: 	If VenMoUsed <> "" Then
0129: 	rs("VenMoUsed").Value = True
0130: 	Else
0131: 	rs("VenMoUsed").Value = False
0132: 	End If	
0133: 	If ZelleUsed <> "" Then
0134: 	rs("ZelleUsed").Value = True
0135: 	Else
0136: 	rs("ZelleUsed").Value = False
0137: 	End If
0138: 
0139: 	rs.Update
0140: 	rs.Close
0141: 	Set rs = Nothing
0142: 	
0143: 		
0144: 		Set rsm = Server.CreateObject("ADODB.Recordset")
0145: 	sqlString = "SELECT * FROM MY4_Master " & _
0146: 							"WHERE RegNumber = '" & RegNumber & "' " 
0147: 	rsm.Open sqlString, conn2, adOpenDynamic, adLockOptimistic, adCmdText
0148: 	If rsm.EOF Then
0149: 	
0150: 	Else
0151: 		rsm("FirstName").Value = firstName
0152: 		rsm("LastName").Value = Name
0153: '		If address <> "N/A" Then
0154: 		rsm("Address").Value = address
0155: 		rsm("City").Value = city
0156: 		rsm("State").Value = state
0157: 		rsm("Zip").Value = zip
0158: 	    rsm("PayPalEmailAddress").Value = PayPalEmailAddress
0159: 		rsm("VenMo").Value = VenMo
0160: 		rsm("Zelle").Value = Zelle		
0161: '		End If
0162: 		rsm.Update
0163: 
0164: 		rsm.Close
0165: 		Set rsm = Nothing	
0166:      End If	
0167: 
0168: If EmailIt = "Y" Then
0169: 
0170:    If Entries = PaidEntries Then
0171: 
0172:      EMailFrom = "jt@folga.org" 
0173:      EMailTo = EmailAddress
0174:      EMailSubject = "March Madness Contest - Your donation has been received"
0175:      EMailBody = "Your donation entitles you to make " & PaidEntries & " pick(s) in the contest.<BR><BR>Thank you for participating!<BR> "
0176: 
0177:      If PaidEntries > 1 Then
0178:        S16picks = PaidEntries - 1
0179:        EmailBody = EmailBody & "<br>P.S.: You are also eligible to make " & S16Picks & " pick(s) in the Sweet 16 Contest.<br><br>"
0180:     End If
0181:    
0182:   Else
0183: 
0184:   Difference = Entries - PaidEntries
0185: 
0186:    EMailFrom = "jt@folga.org" 
0187:    EMailTo = EmailAddress
0188:    EMailSubject = "March Madness Contest - Reminder to send your donation"
0189:    EMailBody = "Hi there " & FirstName & ",<br><br>"   
0190:    EMailBody = EmailBody & "Just a gentle reminder to send in your donation.<br><br>"
0191:    EMailBody = EmailBody & "Entries in the contest: " & Entries & "<br>"
0192:    EmailBody = EmailBody & "Donation received for : " & PaidEntries & " entries.<br><br>"
0193:    EmailBody = EmailBody & "Just go to <a href=" & chr(34) & "https://folga.org/mm" & Chr(34) & ">https://folga.org/mm</a> or <a href=" & chr(34) & "https://folga.org/mm/mobile" & Chr(34) & ">https://folga.org/mm/mobile</a> (mobile) and click on <b>Make Your Donation</a>.<br><br>"
0194:    EmailBody = EmailBody & "<BR><BR>Thank you for participating!<BR> "
0195:  
0196: End If
0197: 
0198: sendEmail EMailTo, "", "", EmailSubject, EMailBody, "HTML", ""
0199: 
0200: End If
0201: 
0202: If Email2ndIt = "Y" Then
0203: 
0204: If Entries2nd = Paid2nd Then
0205: 
0206:    EMailFrom = "jt@folga.org" 
0207:    EMailTo = EmailAddress
0208:    EMailSubject = "March Madness (Sweet 16) - Your donation has been received"
0209: 
0210:    If Entries > 1 Then
0211:    EMailBody = "Your donation entitles you to make " & Paid2nd & " additional pick(s) in the Sweet 16 contest.<BR><BR>Thank you for participating!<BR> "
0212: 
0213:    Else
0214:    EMailBody = "Your donation entitles you to make " & Paid2nd & " pick(s) in the Sweet 16 contest.<BR><BR>Thank you for participating!<BR> "
0215:    End If
0216:   
0217: Else
0218: 
0219: Difference = Entries2nd - Paid2nd
0220: 
0221:    EMailFrom = "jt@folga.org" 
0222:    EMailTo = EmailAddress
0223:    EMailSubject = "Reminder: March Madness (Sweet 16 Contest) donation"
0224:    EMailBody = "Hi there " & FirstName & ",<br><br>"   
0225:    EMailBody = EmailBody & "According to our records, we have not received a donation for all your entries into the contest.<br><br>"
0226:    EMailBody = EmailBody & "Entries in the Sweet 16 contest: " & Entries2nd & "<br>"
0227:    EmailBody = EmailBody & "Donation received for : " & Paid2nd & " entries.<br><br>"
0228:       EmailBody = EmailBody & "You can make your donation via this link: http://folga.org/mm/makedonation.asp or http://folga.org/mm/makedonation_m.asp (mobile)<br><br>"
0229:  '  EmailBody = EmailBody & "Send your $20 donation for each entry to:<br>Antonio Toledo Memorial, P.O. Box 2437, Chino, CA  91708.<br><br>"
0230:    EmailBody = EmailBody & "Please send in your donation at your earliest convenience, or your entry may be removed from the contest.<BR><BR>Thank you for participating!<BR> "
0231:  
0232: End If
0233: 
0234:   
0235: sendEmail EMailTo, "", "", EmailSubject, EMailBody, "HTML", ""
0236: 
0237: End If
0238: 
0239: %>
0240: <!-- #include FILE="include/ReturnPageUse.inc" -->
0241: <%
0242: 
0243: If ReturnPage <> "" Then
0244: 	Response.Redirect(ReturnPage)
0245: End If
0246: 
0247:  If from = "deadbeat" Then
0248:  	Response.Redirect("whoisdeadbeat.asp")	
0249:  Else
0250: 	Response.Redirect("whoisin.asp?DB=" & DeadBeat)	
0251: End If
0252: 	
0253: %>
0254: <html>
0255: 
0256: <head>
0257: <title></title>
0258: </head>
0259: 
0260: <body>
0261: </body>
0262: </html>