%@LANGUAGE="VBSCRIPT"%><% ' *** Update Record: construct a sql update statement and execute it MM_editAction = CStr(Request("URL")) If (Request.QueryString <> "") Then MM_editAction = MM_editAction & "?" & Request.QueryString End If If (CStr(Request("MM_update")) <> "" And CStr(Request("MM_recordId")) <> "") Then MM_tableName = "smo.smo" MM_tableCol = "clave" MM_recordId = "'" + Request.Form("MM_recordId") + "'" MM_fields = "visualizacion,visualizacion,',none,''" MM_redirectPage = "clubsmowelcome.asp" ' create the sql update statement MM_updateStr = "update " & MM_tableName & " set " MM_fieldsArray = Split(MM_fields, ",") For i = LBound(MM_fieldsArray) To UBound(MM_fieldsArray) Step 5 FormVal = CStr(Request.Form(MM_fieldsArray(i))) Delim = MM_fieldsArray(i+2) If (Delim = "none") Then Delim = "" AltVal = MM_fieldsArray(i+3) If (AltVal = "none") Then AltVal = "" EmptyVal = MM_fieldsArray(i+4) If (EmptyVal = "none") Then EmptyVal = "" If (FormVal = "") Then FormVal = EmptyVal Else If (AltVal <> "") Then FormVal = AltVal ElseIf (Delim = "'") Then ' escape quotes FormVal = "'" & Replace(FormVal,"'","''") & "'" Else FormVal = Delim + FormVal + Delim End If End If If (i <> LBound(MM_fieldsArray)) Then MM_updateStr = MM_updateStr & "," End If MM_updateStr = MM_updateStr & MM_fieldsArray(i+1) & " = " & FormVal Next MM_updateStr = MM_updateStr & " where " & MM_tableCol & " = " & MM_recordId ' finish the sql and execute it Set MM_updateCmd = Server.CreateObject("ADODB.Command") MM_updateCmd.ActiveConnection = "dsn=smo;uid=root;pwd=seldon5;" MM_updateCmd.CommandText = MM_updateStr MM_updateCmd.Execute ' redirect with URL parameters If (MM_redirectPage = "") Then MM_redirectPage = CStr(Request("URL")) End If If (InStr(1, MM_redirectPage, "?", vbTextCompare) = 0 And Request.QueryString <> "") Then MM_redirectPage = MM_redirectPage & "?" & Request.QueryString End If Call Response.Redirect(MM_redirectPage) End If %> <% Dim smoclubdatos__MMColParam smoclubdatos__MMColParam = "0" if(Request.Form("celular") <> "") then smoclubdatos__MMColParam = Request.Form("celular") Dim smoclubdatos__MMColParam2 smoclubdatos__MMColParam2 = "0" if(Request.Form("vclave") <> "") then smoclubdatos__MMColParam2 = Request.Form("vclave") %> <% set smoclubdatos = Server.CreateObject("ADODB.Recordset") smoclubdatos.ActiveConnection = "dsn=smo;uid=root;pwd=seldon5;" smoclubdatos.Source = "SELECT * FROM smo.smo WHERE celular = '" + Replace(smoclubdatos__MMColParam, "'", "''") + "' and clave = '" + Replace(smoclubdatos__MMColParam2, "'", "''") + "'" smoclubdatos.CursorType = 0 smoclubdatos.CursorLocation = 2 smoclubdatos.LockType = 3 smoclubdatos.Open smoclubdatos_numRows = 0 %>
<% If Not smoclubdatos.EOF Or Not smoclubdatos.BOF Then %>
Estado de tu Membresia
Si tienes cualquier interrogante escribenos a webmaster@mail.celtel.net
<% End If ' end Not smoclubdatos.EOF Or NOT smoclubdatos.BOF %>
<% If smoclubdatos.EOF And smoclubdatos.BOF Then %>Lo
siento pero los datos ingresados no estan correctos
Si tienes cualquier interrogante escribenos a webmaster@mail.celtel.net<% End If ' end smoclubdatos.EOF And smoclubdatos %>
<% End If ' end Not smoclubdatos.EOF Or NOT smoclubdatos.BOF %>