tengo una pagina con datos de una base de datos y un boton que pasa el id de ese registro a otra pagina de detalle, lo que deseo es que esto sea oculto para el usuario y que el boton que pasa los valores se active automaticamente sin que el usuario le de clic.
Código ASP:
Ver original
<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%> <!--#include file="Connections/xxxxxxxx.asp" --> <% Dim Recordset1 Dim Recordset1_cmd Dim Recordset1_numRows Set Recordset1_cmd = Server.CreateObject ("ADODB.Command") Recordset1_cmd.ActiveConnection = MM_conngdc_STRING Recordset1_cmd.CommandText = "SELECT * FROM requisicion ORDER BY Idrequi DESC" Recordset1_cmd.Prepared = true Set Recordset1 = Recordset1_cmd.Execute Recordset1_numRows = 0 %> <% Dim MM_paramName %> <% ' *** Go To Record and Move To Record: create strings for maintaining URL and Form parameters Dim MM_keepNone Dim MM_keepURL Dim MM_keepForm Dim MM_keepBoth Dim MM_removeList Dim MM_item Dim MM_nextItem ' create the list of parameters which should not be maintained MM_removeList = "&index=" If (MM_paramName <> "") Then MM_removeList = MM_removeList & "&" & MM_paramName & "=" End If MM_keepURL="" MM_keepForm="" MM_keepBoth="" MM_keepNone="" ' add the URL parameters to the MM_keepURL string For Each MM_item In Request.QueryString MM_nextItem = "&" & MM_item & "=" If (InStr(1,MM_removeList,MM_nextItem,1) = 0) Then MM_keepURL = MM_keepURL & MM_nextItem & Server.URLencode(Request.QueryString(MM_item)) End If Next ' add the Form variables to the MM_keepForm string For Each MM_item In Request.Form MM_nextItem = "&" & MM_item & "=" If (InStr(1,MM_removeList,MM_nextItem,1) = 0) Then MM_keepForm = MM_keepForm & MM_nextItem & Server.URLencode(Request.Form(MM_item)) End If Next ' create the Form + URL string and remove the intial '&' from each of the strings MM_keepBoth = MM_keepURL & MM_keepForm If (MM_keepBoth <> "") Then MM_keepBoth = Right(MM_keepBoth, Len(MM_keepBoth) - 1) End If If (MM_keepURL <> "") Then MM_keepURL = Right(MM_keepURL, Len(MM_keepURL) - 1) End If If (MM_keepForm <> "") Then MM_keepForm = Right(MM_keepForm, Len(MM_keepForm) - 1) End If ' a utility function used for adding additional parameters to these strings Function MM_joinChar(firstItem) If (firstItem <> "") Then MM_joinChar = "&" Else MM_joinChar = "" End If End Function %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Documento sin título</title> </head> <body> <table width="100%" border="0" cellspacing="0" cellpadding="2"> <tr> <td>Procesando...</td> <td> </td> <td> </td> <td> </td> </tr> <tr> <td><%=(Recordset1.Fields.Item("Idrequi").Value)%></td> <td><%=(Recordset1.Fields.Item("estado").Value)%></td> <td><%=(Recordset1.Fields.Item("fecha").Value)%></td> <td><a href="requisicion3.asp?<%= Server.HTMLEncode(MM_keepNone) & MM_joinChar(MM_keepNone) & "Idrequi=" & Recordset1.Fields.Item("Idrequi").Value %>"><img src="imagen.gif" width="10" height="10" border="0" /></a></td> </tr> </table> <p> </p> <p> </p> </body> </html> <% Recordset1.Close() Set Recordset1 = Nothing %>
desde ya mil gracias por su ayuda!!!