-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuilderHome.php
More file actions
232 lines (215 loc) · 7.56 KB
/
builderHome.php
File metadata and controls
232 lines (215 loc) · 7.56 KB
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
<!DOCTYPE html>
<html lang="en">
<head>
<title>PropWave</title>
<meta charset="UTF-8">
<meta name="description" content="HOUSING-CO">
<meta name="keywords" content="LERAMIZ, unica, creative, html">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- Favicon -->
<link href="img/favicon.ico" rel="shortcut icon"/>
<!-- Google Fonts -->
<link href="https://fonts.googleapis.com/css?family=Source+Sans+Pro" rel="stylesheet">
<!-- Stylesheets -->
<link rel="stylesheet" href="css/bootstrap.min.css"/>
<link rel="stylesheet" href="css/font-awesome.min.css"/>
<link rel="stylesheet" href="css/animate.css"/>
<link rel="stylesheet" href="css/owl.carousel.css"/>
<link rel="stylesheet" href="css/style.css"/>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js"></script>
<link rel="stylesheet" type="text/css" href="Styles.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
</head>
<body>
<div id="preloder">
<div class="loader"></div>
</div>
<!-- Header section -->
<header class="header-section">
<div class="header-top">
<div class="container">
<div class="row">
<div class="col-lg-6 header-top-left">
<div class="top-info ">
<h3>DashBoard</h3>
</div>
</div>
<div class="col-lg-6 text-lg-right header-top-right">
<div class="top-social">
<a href="https://www.facebook.com/"><i class="fa fa-facebook"></i></a>
<a href="https://www.twitter.com/"><i class="fa fa-twitter"></i></a>
<a href="https://www.instagram.com/"><i class="fa fa-instagram"></i></a>
<a href="https://www.pinterest.com/"><i class="fa fa-pinterest"></i></a>
<a href="https://www.linkedin.com/"><i class="fa fa-linkedin"></i></a>
</div>
<div class="user-panel">
<a href="logout.php"><?php session_start(); echo $_SESSION['username']." ";?><i class="fa fa-user-circle-o"></i>Logout</a>
</div>
</div>
</div>
</div>
</div>
<div class="container">
<div class="row">
<div class="col-12">
<div class="site-navbar">
<a href="#" class="site-logo"><img src="img/logo1.png" alt=""></a>
<div class="nav-switch">
<i class="fa fa-bars"></i>
</div>
<ul class="main-menu">
<?php
if($_SESSION['type']=='builder')
{
echo "<li><a href='builderHome.php'>Home</a></li>";
}
else
{
echo "<li><a href='normalHomeSale.php'>Home</a></li>";
}
?>
<li><a href="addup.php">Add Upcoming Projects</a></li>
<li><a href="upcomingprojects.php">My Upcoming Projects</a></li>
<li><a href="PackersAndMovers.php">Packers And Movers</a></li>
</ul>
</div>
</div>
</div>
</div>
</header>
<!-- Header section end -->
<!-- Hero section -->
<section class="hero-section set-bg" data-setbg="img/bg.jpg">
<div class="container hero-text text-white">
<h2>List your building on our website</h2>
<a href="addprojectsale.php" class="site-btn">Add Now</a>
</div>
</section>
<!-- Hero section end -->
<?php
include('indexDB.php');
$loc=$c='';
$x1="select distinct location from flat";
$x2="select distinct city from flat";
$q="select * from cardsale order by time desc";
if(isset($_POST['loc']) && isset($_POST['city']))
{
$loc=$_POST['loc'];
$c=$_POST['city'];
if($loc=='All' && $c=='All')
{
$q="select * from cardsale order by time desc";
}
if($loc=='All' && $c!='All')
{
$q="select * from cardsale where city='$c' order by time desc";
}
if($loc!='All')
{
$x2="select city from cardsale where location='$loc'";
$q="select * from cardsale where location='$loc' order by time desc";
}
}
$r1=$conn->query($x1);
$r2=$conn->query($x2);
?>
<!-- Filter form section -->
<div class="filter-search">
<div class="container">
<form class="filter-form" method="post" action="builderHome.php">
<h2>Search by Location</h2>
<h4> Location City</h4>
<select name="loc">
<option value="All" selected>All</option>
<?php
while($p1=mysqli_fetch_array($r1, MYSQLI_ASSOC))
{
echo "<option value='".$p1['location']."'>".$p1['location']."</option>";
}
?>
</select>
<select name="city">
<option value="All" selected>All</option>
<?php
while($p2=mysqli_fetch_array($r2, MYSQLI_ASSOC))
{
echo "<option value='".$p2['city']."'>".$p2['city']."</option>";
}
?>
</select>
<button class="site-btn fs-submit" type="submit">SEARCH</button>
</form>
</div>
</div>
<!-- page -->
<section class="page-section categories-page">
<br><br>
<h2 align="center">All Properties</h2>
<br><br>
<div class="container">
<div class="row">
<?php
$r = $conn->query($q);
while($x=mysqli_fetch_array($r, MYSQLI_ASSOC))
{
?>
<div class='col-md-4' style="height:300px;">
<form action='single-list_sale.php?action=add&id=<?php echo $x['flat_id']; ?>' method="post">
<div class='sale-notic'>FOR Sale</div>
<div class='propertie-info text-white' style="background-image:url('<?php echo $x['image'] ?>');height:270px">
<div class='info-warp'>
<p><i class='fa fa-map-marker'></i><?php echo $x['location'] ?></p>
</div>
<button class='price' type='submit'><?php echo "Rs. ".$x['totalcost'] ?></button>
</div>
</form>
</div>
<?php
}
?>
</div>
</div>
<br><br>
<h2 align="center">Your Properties</h2>
<br><br><div class="container">
<div class="row">
<?php
$ab="select * from flat natural join sale where bid=".$_SESSION['id']."";
$r1 = $conn->query($ab);
while($y=mysqli_fetch_array($r1, MYSQLI_ASSOC))
{
?>
<div class='col-md-4' style="height:300px;">
<form action='single-list_sale.php?action=add&id=<?php echo $y['flat_id']; ?>' method="post">
<div class='sale-notic'>FOR Sale</div>
<div class='propertie-info text-white' style="background-image:url('<?php echo $y['image'] ?>');height:270px">
<div class='info-warp'>
<p><i class='fa fa-map-marker'></i><?php echo $y['location'] ?></p>
</div>
<button class='price' type='submit'><?php echo "Rs. ".$y['totalcost'] ?></button>
</div>
</form>
</div>
<?php
}
?>
</div>
</div>
</section>
<!-- Footer section end -->
<!--====== Javascripts & Jquery ======-->
<script src="js/jquery-3.2.1.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="js/owl.carousel.min.js"></script>
<script src="js/masonry.pkgd.min.js"></script>
<script src="js/magnific-popup.min.js"></script>
<script src="js/main.js"></script>
</body>
</html>