Kendimizin kurduğu kulup içim bir site yapıyorum iki kategorili arama yaptırıyorum arama kriterlerini veri tabanından çekiyorum ama birtürlü bulmuyor kafayı yemek üzereyim yardımı olucak arkadaşa şimdiden teşekkürler
not bittikten sonra bu arama motorunu sitede yayınlıyacağım..
kodlar şağıdaki gibidir...
arama.asp
<form action="sonuc1.asp" method=post>
<div class="style1">
<select name="aranan1" onchange="document.location.href='arama.asp?motorK odu='+ this.options[this.selectedIndex].value;">
<% If Request("motorKodu") = "" Then %>
<%
Set kayit = Server.CreateObject("ADODB.RecordSet")
kayit.Open "SELECT * FROM model ", baglantim, 1, 3
git = Request.QueryString("git")
if git="" then
git=1
end if%> <option selected>Seçiniz</option>
<%
kayit.pagesize = 10000
kayit.absolutepage = git
sayfa = kayit.pagecount
for i=1 to kayit.pagesize
if kayit.eof or kayit.bof then exit for
%>
<option value="<%=kayit("id")%>"><%=kayit("model")%><%if kayit.recordcount>0 then%>
<%end if%></option>
<%kayit.MoveNext
Next %> <% end if%>
<% If Request("motorKodu") <> "" Then %>
<%
Alfa=Request("motorKodu")
Set kayit = Server.CreateObject("ADODB.RecordSet")
kayit.Open "SELECT * FROM model where id="&Alfa, baglantim, 1, 3
git = Request.QueryString("git")
if git="" then
git=1
end if%>
<%
kayit.pagesize = 10000
kayit.absolutepage = git
sayfa = kayit.pagecount
for i=1 to kayit.pagesize
if kayit.eof or kayit.bof then exit for
%>
<option value="<%=kayit("id")%>"><%=kayit("model")%><%if kayit.recordcount>0 then%>
<%end if%></option>
<%kayit.MoveNext
Next %> <% end if%>
</select><br>
<select size="1" name="aranan2" style="font-family: Arial; font-size: 9pt">
<% If Request("motorKodu") <> "" Then %>
<%
Alfa=Request("motorKodu")
Set kayit = Server.CreateObject("ADODB.RecordSet")
kayit.Open "SELECT * FROM motor where model="&Alfa, baglantim, 1, 3
git = Request.QueryString("git")
if git="" then
git=1
end if%>
<%
kayit.pagesize = 10000
kayit.absolutepage = git
sayfa = kayit.pagecount
for i=1 to kayit.pagesize
if kayit.eof or kayit.bof then exit for
%>
<option value="<%=kayit("id")%>"><%=kayit("motor")%>
<%if kayit.recordcount>0 then%>
<%end if%></option>
<%kayit.MoveNext
Next %>
<%end if%>
</select></div>
<input name="B1" type="submit" value="ara" style="height: 19px">
sonuc1.asp
<%
Set baglanti=Server.CreateObject("ADODB.Connection")
baglanti.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath("veri__/alfisti_.mdb")
%>
<%
aranan1 = request("aranan1")
aranan2 = request("aranan2")
Set kayit = Server.CreateObject("ADODB.RecordSet")
sql="select * from alfalar WHERE model like '%" & aranan1 & "%' and motor like '%" & aranan2 & "%' "
kayit.Open SQL,baglanti,1,3
'Toplam Kayıt Sayısını Bulduk
radet = kayit.recordcount
kd= Request.QueryString("kd")
if kd="" then
kd=1
end if
%>
<table border="1" width="90%" id="table2" style="border-width: 0px">
<tr>
<td style="border-style: none; border-width: medium">
<p align="center"><b>
<font color="#D80D1A" face="Arial" style="font-size: 10pt">Toplam <%=radet%>
Adet Sonuç Bulundu...</font></b></td>
</tr>
</table>
<table border="1" width="91%" id="table3" style="border-width: 0px">
<tr>
<td style="border-style: none; border-width: medium" width="71%">
<font color="#FFFFFF"><span style="font-size: 7pt">.</span></font></td>
</tr>
</table>
<%
if kayit.Eof Then
Response.Write "Aradığınız Alfa Romeo Bulunamadı...<br><br>"
Else
%>
<%
kayit.pagesize = 30
kayit.absolutepage = kd
sayfa = kayit.pagecount
for i=1 to kayit.pagesize
if kayit.eof or kayit.bof then exit for
%>
<br>
<table style="width: 100%">
<tr>
<td colspan="2" class="style1"><strong>Karoser ve Boyutları</strong></td>
</tr>
<tr>
<td class="style6" style="width: 210px"><strong>Karaser Tipi</strong></td>
<td class="style6"><%=kayit("karosertipi")%></td>
</tr>
<tr>
<td class="style4" style="width: 210px"><strong>Kapı Sayısı</strong></td>
<td class="style4"> </td>
</tr>
<tr>
<td class="style3" style="width: 210px"><strong>Dingil Mesafesi</strong></td>
<td class="style3"> </td>
</tr>
<tr>
<td class="style3" style="width: 210px"><strong>Ön İz Genişliği</strong></td>
<td class="style3"> </td>
</tr>
<tr>
<td class="style3" style="width: 210px"><strong>Uzunluk</strong></td>
<td class="style3"> </td>
</tr>
<tr>
<td class="style3" style="width: 210px"><strong>Genişlik</strong></td>
<td class="style3"> </td>
</tr>
<tr>
<td class="style3" style="width: 210px"><strong>Yükseklik</strong></td>
<td class="style3"> </td>
</tr>
<tr>
<td class="style3" style="width: 210px"><strong>Uzunluk / Dingil Mesafesi Oranı</strong></td>
<td class="style3"> </td>
</tr>
<tr>
<td class="style3" style="width: 210px"><strong>Ağırlık</strong></td>
<td class="style3"> </td>
</tr>
<tr>
<td class="style5" style="width: 210px"><strong>Yakıt Kapasitesi</strong></td>
<td class="style5"> </td>
</tr>
<tr>
<td class="style1" colspan="2"><strong>Aerodinamik</strong></td>
</tr>
<tr>
<td class="style2" style="width: 210px">Hava Sözlürtünme Katsayısı</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style1" colspan="2"><strong>Motor Özellikleri</strong></td>
</tr>
<tr>
<td class="style2" style="width: 210px">Motor Üreticisi</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Motor Yeri</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Motor Yerleşimi</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Motor Tipi</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Silindir Sayısı ve Yerleşimi</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Slindir Başına Subab Sayısı</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Motor Hacmi</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Sıkıştırma Oranı</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Yakıt Besleme Tipi</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Hava Besleme Türü</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">İntercooler Türü</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Katalatik Konvertor</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Maksimum Motor Gücü</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Maksimum Güç Devri</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Maksimum Tork</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Maksimum Tork Devri</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Maksimum Güç Devrinde Tork</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Güç / Ağırlık Oranı</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Güç Motor Hacimi Oranı</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style1" colspan="2"><strong>Performans</strong></td>
</tr>
<tr>
<td class="style2" style="width: 210px">0 - 80 km/h</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">0 - 60 km/h</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">0 - 100 km/h</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">0 - 160 km/h</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">80 - 120 km/h</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">0 - 400 m Hızlanma</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">0 - 1000 m Hızlanma</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Son Sürat</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style1" colspan="2"><strong>Şanzıman Aktarma</strong></td>
</tr>
<tr>
<td class="style2" style="width: 210px">Şanzıman Türü</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Son Vites Dişli Oranı</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Son Dişli Oranı</td>
<td class="style2"> </td>
</tr>
<tr>
<td class="style2" style="width: 210px">Aktarma</td>
<td class="style2"> </td>
</tr>
</table>
<br>
<br>
<br>
<%
kayit.MoveNext
next
%>
<table border="1" width="91%" id="table5" style="border-width: 0px">
<tr>
<td style="border-style: none; border-width: medium" align="center">
<b>
<font face="Arial" style="font-size: 9pt" color="#D80D1A">
<%
for y=1 to sayfa
if kd=y then
response.write y
else
response.write "<b> <a href=""sonuc1.asp?kd="&y&"&aranan1="&aranan1&"&ara nan2="&aranan2&""">"&y&"</a></b>"
end if
next
%>
<%end if%>
</font>
</b></td>
</tr>
</table>
</body>
Kafayı yemek üzereyim acil yardım...
4
●560
- 10-08-2009, 23:49:34
- 10-08-2009, 23:53:39ayrıca tüm veri tabanı aşdaki linkte
http://www.alfisti.biz/deneme/veri.rar
Herkeze şimdiden teşekkürler