Visualizzazione dei risultati da 1 a 2 su 2

Discussione: impaginazione

  1. #1
    Utente di HTML.it
    Registrato dal
    May 2006
    Messaggi
    172

    impaginazione

    salve ho fatto 4 pagine asp, il mio problema che deve farle diventare una sola pagina possibilmento con un solo bottone filtra ...ma non so come fare, o melgio ci ho provato ma mi viene un casino....chi mi può dare una mano spero di essere stato chiaro!!!
    1) pagina



    <form name="filtraDati" action="r_data_pi.asp" method="POST">
    <table width="25%" border="0" align="center">
    <tr>
    <th colspan="2">Inserire una data PI</th>
    </tr>
    <tr>
    <td>Dal</td>
    <td><input name="data" size="10" onclick="if(self.gfPop)gfPop.fPopCalendar(this);re turn false;" style="font-size : smaller;" readonly></td>
    </tr>
    <tr>
    <td>Al</td>
    <td><input name="data1" size="10" onclick="if(self.gfPop)gfPop.fPopCalendar(this);re turn false;" style="font-size : smaller;" readonly></td>
    </tr>
    <tr>
    <td colspan="2" align="center"><input type="button" value="cerca" onclick="if(document.all.data.value!='' && document.all.data1.value!=''){document.all.filtraD ati.submit();}else{alert('Attenzione! Valorizza i campi data');}" size="10"></td>
    </tr>
    </table>

    </form>

















    <p align="center"><input type="button" value="Torna Indietro" onclick="history.back()"></p>


    <iframe width=174 height=189 name="gToday:normal:agenda.js" id="gToday:normal:agenda.js" src="js_calendar/cal.htm" scrolling="no" frameborder="0" style="visibility:visible; z-index:999; position:absolute; top:-500px; left:-500px;"></iframe>

    </body>
    </html>

    2)
    <table width="40%" border="1" heigt="300" align="center">
    <tr>
    <td align=center>
    <th>Risultato di ricerca delle PI per data </th>
    </table>




    <table border="1" bgcolor="white" cellspacing="1" cellpadding="1" align="center" bordercolor="blue">
    <tr>
    <th>Ord.</th>
    <th>Cod.Agesp</th>
    <th>Titolo PI</th>
    <th>Data PI</th>

    </tr>
    <form>

    <%
    Dim variabile1
    ' Apertura del Database e creazione recordSet
    Set objConn = Server.CreateObject("ADODB.Connection")
    objConn.Open("Provider = Microsoft.Jet.OLEDB.4.0; Data Source = c:/mdb/Gestione_PI_Tickets.mdb")
    set rs = server.createobject("ADODB.recordset")
    sql = "SELECT * FROM CdT WHERE data_PI between format('" & Request.Form("data") & "','dd/mm/yyyy') and format('" & Request.Form("data1") & "','dd/mm/yyyy')"
    Set rs = Server.CreateObject("ADODB.Recordset")
    rs.open sql, objconn
    if not rs.eof then
    do while not(rs.eof)

    variabile1 = rs("Titolo_PI")

    %>
    <tr>

    <td align="center"><font size="2" font face="arial"><%response.write(rs("id"))%></font></td>
    <td><font align="center"><font size="2" font face="arial"><%response.write( Request.Form("sistema"))%></font></td>
    <td><font size="2" face="verdana"><%response.write("" & rs("cod_agesp") & "")%></font></td>
    <td align="center" ><font size="2" font face="arial"><%response.write("" & rs("Titolo_PI") & "")%></font></td>
    <td align="center" ><font size="2" font face="arial"><%response.write(rs("data_PI"))%></font></td>
    <tr>



    <%
    rs.movenext
    Loop

    rs.Close
    set rs = Nothing
    objConn.close

    else
    %>
    <table width="40%" border="4" heigt="300" align="center">
    <tr>
    <td align=center>
    <%
    Response.Redirect "pag_messagio.asp"
    %>
    </td>
    </tr>
    </table>
    <%
    end if
    %>
    </form>
    </table>
    <p align="center"><input type="button" value="Torna Indietro" onclick="history.back()"></p>

    </body>
    </html>

    3)
    <table width="22%" border="0" align="center">
    <td
    <th><td style="font-weight:bold">Inserire Codice Agesp</th>
    <form name="filtraDati" action="ricerca2_agesp.asp" method="POST">
    <input type="text" name="codice_agesp" size="20">
    <input type="submit" value="cerca" size="20">
    </table>
    </form>


    </table>




















    <p align="center"><input type="button" value="Torna Indietro" onclick="history.back()"></p>
    </TR>
    </body>
    </html>
    4)
    <table border="1" bgcolor="white" cellspacing="1" cellpadding="1" align="center" bordercolor="blue">

    <tr>
    <th>Ord.</th>
    <th>Cod.Agesp</th>
    <th>Titolo PI</th>
    <th>Data PI</th>
    </tr>

    <%
    ' Apertura del Database e creazione recordSet
    Set objConn = Server.CreateObject("ADODB.Connection")
    objConn.Open("Provider = Microsoft.Jet.OLEDB.4.0; Data Source = c:/mdb/Gestione_PI_Tickets.mdb")

    set rs = server.createobject("ADODB.recordset")
    ' Devi inserire qui il filtro
    sql = "SELECT * FROM CdT WHERE cod_agesp= '"& Request.Form("codice_agesp")&" ' "
    'response.write(sql)
    Set rs = Server.CreateObject("ADODB.Recordset")
    rs.open sql, objconn
    if not rs.eof then
    do while not(rs.eof)
    dim variabil2
    variabile2 = rs("id")
    Dim variabile1
    variabile1 = rs("Titolo_PI")
    %>
    <tr>
    <td align="center"><font size="2" font face="arial"><%response.write(rs("id"))%></font></td>
    <td><font size="2" face="verdana"><%response.write("" & rs("cod_agesp") & "")%></font></td>
    <td align="center" ><font size="2" font face="arial"><%response.write("" & rs("Titolo_PI") & "")%></font></td>
    <td align="center" ><font size="2" font face="arial"><%response.write(rs("Data_PI"))%></font></td>

    <tr>

    <%
    rs.movenext

    Loop
    rs.Close
    set rs = Nothing
    objConn.close
    %>

    <%

    else
    %>
    <table width="40%" border="4" heigt="300" align="center">
    <tr>
    <td align=center>
    <%

    Response.Redirect "pag_messagio.asp"
    %>
    </td>
    </tr>
    </table>
    <%
    end if
    %>
    </table>

    <p align="center"><input type="button" value="Torna Indietro" onclick="history.back()"></p>
    </TR>
    </body>
    </html>

  2. #2
    Utente di HTML.it L'avatar di viki1967
    Registrato dal
    Feb 2003
    Messaggi
    1,757
    Cerca sul forum per paginazione Roby72.
    A S P : tutto il resto è noia...
    L I N U X : forse mi "converto"...

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2026 vBulletin Solutions, Inc. All rights reserved.