-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathfilter.php
35 lines (35 loc) · 940 Bytes
/
filter.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
<?php
require_once "link.php";
$str='/brokfree/filter.php';
$val1=link_check($str);
if($val1):
ob_start();
include "templates/error.html";
$out=ob_get_clean();
echo $out;
exit();
endif;
if(isset($_GET['min']) && isset($_GET['min']))
{
$min=(int)$_GET['min'];
$max=(int)$_GET['max'];
$q1=' AND rent BETWEEN :min AND :max';
$array['min']=$min;
$array['max']=$max;
}
if(isset($_GET['radio'])):
$q1.=' AND bedroom=:bed';
$array['bed']=(int)$_GET['radio'];
endif;
if(isset($_GET['radio1'])):
$q1.=' AND water=:water';
$array['water']=$_GET['radio1'];
endif;
if(isset($_GET['radio2'])):
$q1.=' AND pt=:pt';
$array['pt']=$_GET['radio2'];
endif;
if(isset($_GET['radio3'])):
$q1.=' AND furnishing=:fur';
$array['fur']=$_GET['radio3'];
endif;