-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathliste.php
83 lines (60 loc) · 1.96 KB
/
liste.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
<?
require_once "1.php";
if($get->akno)
$sql=mysql_query("SELECT * FROM urunler WHERE kno=$get->akno ORDER BY no DESC ");
elseif($get->ara)
$sql=mysql_query("SELECT * FROM urunler WHERE ad LIKE '%$get->ara%' ORDER BY no DESC ");
else
$sql=mysql_query("SELECT * FROM urunler ORDER BY no DESC ");
$limit=21;
if(empty($get->sayfa)) { $get->sayfa ="1"; }
$sayi = mysql_num_rows($sql);
$kac_tane = $sayi / $limit;
if($kac_tane%$limit>"0") { $kac_tane++; }
$son = ($get->sayfa-1)*$limit;
if($get->akno)
$sql=mysql_query("SELECT * FROM urunler WHERE kno=$get->akno ORDER BY no DESC limit $son,$limit");
elseif($get->ara)
$sql=mysql_query("SELECT * FROM urunler WHERE ad LIKE '%$get->ara%' ORDER BY no DESC limit $son,$limit");
else
$sql=mysql_query("SELECT * FROM urunler ORDER BY no DESC limit $son,$limit");
if($get->kno && $get->akno){
$ksql=mysql_query("SELECT * FROM kategoriler WHERE no=$get->kno ORDER BY no DESC ");$k=mysql_fetch_object($ksql);
$aksql=mysql_query("SELECT * FROM kategoriler WHERE no=$get->akno ORDER BY no DESC ");$ak=mysql_fetch_object($aksql);
}
if($get->kno)
$baslik= "Ürünler / $k->kategori / $ak->kategori";
elseif($get->ara)
$baslik= "$get->ara / ürünler";
else
$baslik= "Ürünler";
tema_tablo_ac($baslik);
echo "<table><tr>";
$i=0;
$a=0;
while($s=mysql_fetch_object($sql))
{
if($i==ayar_al("vitrin_sutun")){print "</tr><tr>";$a=$a+1;;$i=0;}
if($a==ayar_al("vitrin_satir")){break;}
echo "<td>";
tema_urun_kucuk($s);
$i=$i+1;
echo "</td>";
}
echo "</tr></table>";
tema_tablo_kapat();
echo "<div class=sayfala>";
for($i=1; $i < $kac_tane; $i++)
{
if($get->sayfa==$i)
print "<a class='sayfala-secili' >$i </a>";
else
if($get->akno && $get->kno)
print "<a class='sayfala-sec' href=?sayfa=$i&akno=$get->akno&kno=$get->kno>$i </a>";
else
print "<a class='sayfala-sec' href=?sayfa=$i>$i </a>";
}
print "<div class=temizle></div>";
echo "</div>";
require_once "2.php";
?>