|
|
| |||
| merhaba arkadaşlar yardımınıza ihtiyacım var. default.asp de eklenen ürünler aşağıya doğru sıralnıp uzayıp gitmekte. ben ürünleri yanyan 5 li halde sıralamak istiyorum. örnek 1,2,3,4,5 6,7,8,9,10 111,12,13,14,15 gibi. şimdiki kodum aşağıdakidir. neresini değiştirmem lazım Kod: <!--#include file="up_incs/meta.asp"-->
<link rel="canonical" href="<%=strASiteURL%>/" />
<title><%=strSiteTit%></title>
<meta name="keywords" content="<%=strSiteKey%>" />
<meta name="description" content="<%=strSiteTit%>" />
</head>
<body>
<!-- end #header-wrapper -->
<!--#include file="up_incs/header.asp"-->
<div id="slideshow">
<!-- start -->
<div id="foobar">
<div id="col1"><a href="#" class="previous"> </a></div>
<div id="col2">
<div class="viewer">
<div class="reel">
<%
' * * ** * * ** * * * ** * * * * ** * * *** ** * * * *** * * ** * * * ** *
Set rsCommon = Server.CreateObject("ADODB.Recordset")
rsCommon.ActiveConnection = adoCon
rsCommon.Source = "SELECT * From tblUrun Where UManset <> "&"0"&" Order By UID DESC"
rsCommon.CursorLocation = 3
rsCommon.LockType = 1
rsCommon.Open()
Do While Not rsCommon.Eof
UResim = rsCommon("UResim")
UHit = rsCommon("UHit")
UTarih = rsCommon("UTarih")
If strSiteDil = "en" Then
UBaslik = rsCommon("UBaslikEN")
ElseIf strSiteDil = "ru" Then
UBaslik = rsCommon("UBaslikRU")
ElseIf strSiteDil = "ar" Then
UBaslik = rsCommon("UBaslikAR")
Else
UBaslik = rsCommon("UBaslikTR")
End If
%>
<div class="slide">
<div align="center"><img src="<%=strASiteURL%>/uploads/urun/<%If Uresim <> "" Then%><%=UResim%><%Else%>no-image.png<%End If%>" width="500" height="225" alt="" />
<a href="urun.asp?id=<%=rsCommon("UID")%>"><span><%=UBaslik%></span></a>
</div>
</div>
<%
rsCommon.MoveNext : Loop
rsCommon.Close
Set rsCommon = Nothing
' * * ** * * ** * * * ** * * * * ** * * *** ** * * * *** * * ** * * * ** *
%>
</div>
</div>
</div>
<div id="col3"><a href="#" class="next"> </a></div>
</div>
<script type="text/javascript">
$('#foobar').slidertron({
viewerSelector: '.viewer',
reelSelector: '.viewer .reel',
slidesSelector: '.viewer .reel .slide',
navPreviousSelector: '.previous',
navNextSelector: '.next',
navFirstSelector: '.first',
navLastSelector: '.last'
});
</script>
<!-- end -->
</div>
<div id="page">
<div id="page-bgtop">
<div id="content">
<%
strSay = 0
' * * ** * * ** * * * ** * * * * ** * * *** ** * * * *** * * ** * * * ** *
Set rsCommon = Server.CreateObject("ADODB.Recordset")
rsCommon.ActiveConnection = adoCon
rsCommon.Source = "SELECT * From tblUrun Order By UID DESC"
rsCommon.CursorLocation = 3
rsCommon.LockType = 1
rsCommon.Open()
strToplam = rsCommon.RecordCount
If strToplam = 0 Then
strSayfaSay = 0
Else
strGecerliSayfa = Request.QueryString("p")
If strGecerliSayfa = "" OR IsNumeric(strGecerliSayfa) = False Then strGecerliSayfa = 1
rsCommon.PageSize = strASayfalama
strSayfaSay = rsCommon.PageCount
rsCommon.AbsolutePage = strGecerliSayfa
For strSay = 1 To strASayfalama
If rsCommon.Eof Then Exit For
UResim = rsCommon("UResim")
UHit = rsCommon("UHit")
UTarih = rsCommon("UTarih")
If strSiteDil = "en" Then
UBaslik = rsCommon("UBaslikEN")
UOzet = rsCommon("UOzetTR")
ElseIf strSiteDil = "ru" Then
UBaslik = rsCommon("UBaslikRU")
UOzet = rsCommon("UOzetTR")
ElseIf strSiteDil = "ar" Then
UBaslik = rsCommon("UBaslikAR")
UOzet = rsCommon("UOzetTR")
Else
UBaslik = rsCommon("UBaslikTR")
UOzet = rsCommon("UOzetTR")
End If
%>
<div class="post">
<p class="meta"><%=strTarih%>: <span class="date"><%=FormatDateTime(UTarih, 1)%></span> <%=strHit%>: <a><%=UHit%></a></p>
<h2 class="title"><a href="urun.asp?id=<%=rsCommon("UID")%>"><%=UBaslik%></a></h2>
<div class="entry">
<p><img src="<%=strASiteURL%>/uploads/urun/<%If UResim <> "" Then%><%=UResim%><%Else%>no-image.png<%End If%>" width="560" height="270" alt="" /><%=UOzet%></p>
</div>
<div><a href="urun.asp?id=<%=rsCommon("UID")%>" class="links"><%=strDevami%></a></div>
</div>
<%If strSay = 1 Then%>
<div style="padding:8px; height:98px" align="center" class="post">
<%
' * * ** * * ** * * * ** * * * * ** * * *** ** * * * *** * * ** * * * ** *
Set rsCommonV = Server.CreateObject("ADODB.Recordset")
rsCommonV.ActiveConnection = adoCon
rsCommonV.Source = "SELECT * From tblVideoKtg Order By VKID Desc"
rsCommonV.CursorLocation = 3
rsCommonV.LockType = 1
rsCommonV.Open()
For im = 1 To 3
If rscommonV.Eof Then Exit For
%>
<a href="video-detay.asp?id=<%=rsCommonV("VKID")%>" style="text-decoration:none;"><img src="<%=strASiteURL%>/uploads/video/<%If rsCommonV("VKResim") <> "" Then%><%=rsCommonV("VKResim")%><%Else%>no-image.png<%End If%>" width="180" height="87" alt="" style="margin:5px 5px 5px 5px; border:1px #666666 solid;" /></a>
<%
rsCommonV.MoveNext : Next
rsCommonV.Close
Set rsCommonV = Nothing
' * * ** * * ** * * * ** * * * * ** * * *** ** * * * *** * * ** * * * ** *
%>
</div>
<%End If%>
<%
rsCommon.MoveNext : Next
End If
rsCommon.Close
Set rsCommon = Nothing
' * * ** * * ** * * * ** * * * * ** * * *** ** * * * *** * * ** * * * ** *
%>
<div style="padding:8px; height:98px" align="center" class="post">
<%
' * * ** * * ** * * * ** * * * * ** * * *** ** * * * *** * * ** * * * ** *
Set rsCommon = Server.CreateObject("ADODB.Recordset")
rsCommon.ActiveConnection = adoCon
rsCommon.Source = "SELECT * From tblGaleriKtg Order By GKID Desc"
rsCommon.CursorLocation = 3
rsCommon.LockType = 1
rsCommon.Open()
For im = 1 To 3
If rscommon.Eof Then Exit For
%>
<a href="galeri-detay.asp?id=<%=rsCommon("GKID")%>" style="text-decoration:none;"><img src="<%=strASiteURL%>/uploads/galeri/<%If rsCommon("GKResim") <> "" Then%><%=rsCommon("GKResim")%><%Else%>no-image.png<%End If%>" width="180" height="87" alt="" style="margin:5px 5px 5px 5px; border:1px #666666 solid;" /></a>
<%
rsCommon.MoveNext : Next
rsCommon.Close
Set rsCommon = Nothing
' * * ** * * ** * * * ** * * * * ** * * *** ** * * * *** * * ** * * * ** *
%>
</div>
<div style="padding:8px;" align="center" class="post">
<%
'Sayfalama
Aralik = 2
strSayfaAltSiniri = strGecerliSayfa - Aralik
strSayfaUstSiniri = strGecerliSayfa + Aralik
strSolGrupSayisi = 1 + Aralik
strSagAltSinir = strSayfaSay - Aralik
%>
<%
If (strSayfaUstSiniri > strSayfaSay) Then
strSayfaAltSiniri = strSayfaSay - (2 * Aralik)
strSayfaUstSiniri = strSayfaSay
End If
%>
<%
If (strSayfaAltSiniri <= 0) Then
strSayfaAltSiniri = 1
strSayfaUstSiniri = strSayfaAltSiniri + (2 * Aralik)
If strSayfaUstSiniri >= strSayfaSay Then strSayfaUstSiniri = strSayfaSay
End If
%>
<%
If strSolGrupSayisi >= strSayfaAltSiniri Then strSolGrupSayisi = strSayfaAltSiniri - 1
If strSagAltSinir <= strSayfaUstSiniri Then strSagAltSinir = strSayfaUstSiniri + 1
%>
<%
If strGecerliSayfa >1 Then %>
<a href="?p=1" style="font-weight:bold;">[««]</a>
<a href="?p=<%=strGecerliSayfa-1%>" style="font-weight:bold;">[«]</a><%
End If
%>
<%
For i = 1 to strSolGrupSayisi
If CInt(i) = (strGecerliSayfa) Then
Response.Write " <b>"
Else %>
<a href="?p=<%=i%>" style="font-weight:bold;"><%
End If
Response.Write i &"</a></b>"
Next
%>
<%
If (strSayfaAltSiniri - strSolGrupSayisi >1 ) Then Response.Write "<b>. . .</b>"
%>
<%
For i = strSayfaAltSiniri to strSayfaUstSiniri
If CInt(i) = CInt(strGecerliSayfa) Then
Response.Write " <b>"
Else %>
<a href="?p=<%=i%>" style="font-weight:bold;"><%
End If
Response.Write i &"</a></b>"
Next
%>
<%
If (strSagAltSinir - strSayfaUstSiniri >1) Then Response.Write "<b>. . .</b>"
%>
<%
For i = strSagAltSinir to strSayfaSay
If CInt(i) = CInt(strGecerliSayfa) Then
Response.Write " <b>"
Else %>
<a href="?p=<%=i%>" style="font-weight:bold;"><%
End If
Response.Write i &"</a></b>"
Next
%>
<%
If CInt(strGecerliSayfa) <> CInt(strSayfaSay) Then %>
<a href="?p=<%=strGecerliSayfa+1%>" style="font-weight:bold;">[»]</a>
<a href="?p=<%=strSayfaSay%>" style="font-weight:bold;">[»»]</a><%
End If
%>
</div>
</div>
<!-- end #content -->
<!--#include file="up_incs/sidebar.asp"-->
<!-- end #sidebar -->
<div style="clear: both;"> </div>
</div>
<!-- end #page -->
</div>
<!--#include file="up_incs/footer.asp"-->
__________________ İskele |
| |||
| for komutu ile bunu cok rahat yapabilirsin. |
| |||
| konuyla alakalı pm gönderdim size.. |
| |||
| http://www.r10.net/asp-hazir-kodlar/...-siralama.html Yukardaki konuyu bi incelemeni tavsiye ederim kardeşim. Kolay gesin.
__________________ Bütün Scriptlerde Büyük İndirim - Scriptler | Satış Ortaklığı |
![]() |
| Bookmarks |
| Seçenekler | |
| |