Torna al Thread
<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
<!--#include file="Connections/bibl.asp" -->
<%
Dim Recordset1__MMColParam
Recordset1__MMColParam = "1"
If (Request.Form("Titolo") <> "") Then
Recordset1__MMColParam = Request.Form("Titolo")
else Recordset1__MMColParam="xjtgxdjk"
End If
%>
<%
Dim Recordset1
Dim Recordset1_cmd
Dim Recordset1_numRows
Set Recordset1_cmd = Server.CreateObject ("ADODB.Command")
Recordset1_cmd.ActiveConnection = MM_bibl_STRING
Recordset1_cmd.CommandText = "SELECT * FROM Biblio WHERE Titolo LIKE ?"
Recordset1_cmd.Prepared = true
Recordset1_cmd.Parameters.Append Recordset1_cmd.CreateParameter("param1", 200, 1, 250, "%" + Recordset1__MMColParam + "%") ' adVarChar
Set Recordset1 = Recordset1_cmd.Execute
Recordset1_numRows = 0
%>
<%
Dim Repeat1__numRows
Dim Repeat1__index
Repeat1__numRows = -1
Repeat1__index = 0
Recordset1_numRows = Recordset1_numRows + Repeat1__numRows
%>
<!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>biblio</title>
</head>
<body>
<table width="619" border="0" cellspacing="0" cellpadding="0">
<tr>
<td colspan="2">Ricerca per titolo
<form id="form1" name="form1" method="post" action="">
<label>
<input name="titolo" type="text" id="titolo" />
</label>
<label>
<input type="submit" name="button" id="button" value="Invia" />
</label>
</form></td>
</tr>
<%
While ((Repeat1__numRows <> 0) AND (NOT Recordset1.EOF))
%>
<tr>
<td><%=(Recordset1.Fields.Item("Titolo").Value)%></td>
<td><%=(Recordset1.Fields.Item("Anno").Value)%> <%=(Recordset1.Fields.Item("Edizione").Value)%></td>
</tr>
<%
Repeat1__index=Repeat1__index+1
Repeat1__numRows=Repeat1__numRows-1
Recordset1.MoveNext()
Wend
%>
</table>
<% If Recordset1.EOF And Recordset1.BOF Then %>
<p>nessun risultato</p>
<% End If ' end Recordset1.EOF And Recordset1.BOF %>
</body>
</html>
<%
Recordset1.Close()
Set Recordset1 = Nothing
%>