Vorrei inserire un valore in più alla select tipo "ALL PRODUCTS" e di conseguenza correggere anche la SQL a seconda della mia scelta !
Questa è la pagina con i risultati dove dovrei aggiungere un IF penso a seconda della scelta sulla mia selectcodice:<form method="post" action="result_keyfobs.asp" name="Key-fob Transmitters"> <select name="modulation" class="campiform"> <% do while not rs.EOF %> <option value="<%=rs("modulation")%>"><%=rs("modulation")%></option> <% rs.MoveNext Loop %> </select> <input name="submit" type="submit" class="bottonform" id="submit" value=" Go "> </form>
ovvero se scelgo "ALL PRODUCTS" mi stampo tutto
Come sempre grazie dell'aiuto !codice:<% modulation=request.form("modulation") if modulation="" then modulation=request.querystring("modulation") 'APERTURA CONNESSIONE CON IL DATABASE SENZA DSN Set objConn = Server.CreateObject("ADODB.Connection") objConn.Open "DRIVER={Microsoft Access Driver (*.mdb)};DBQ=" & server.MapPath("/fpdb/wire_products.mdb") strSQL=("SELECT * FROM products where tip_UK = 'key-fob transmitter' and MODULATION='"& modulation &"' order by dataSF DESC") set rs=server.CreateObject("ADODB.recordset") rs.Open strSQL, objConn,3,3 recordsperpage=5 rs.pagesize=recordsperpage Pages=request.querystring("pagina") if (len (Pages)>0 and isnumeric(Pages)) then Pages=clng(Pages) else Pages=1 end if %>![]()
![]()

Rispondi quotando
