-
Notifications
You must be signed in to change notification settings - Fork 0
/
flats3.php
122 lines (75 loc) · 3.57 KB
/
flats3.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
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
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>الوليد | شقق إيجار قديم</title>
<?php $browser = $_SERVER['HTTP_USER_AGENT']; ?>
<?php if (strstr($browser, "MSIE")) { ?>
<link rel="stylesheet" href="stylesheets/articleIEstyle.css" type="text/css" media="screen" />
<?php }else{ ?>
<link rel="stylesheet" href="stylesheets/articlestyle.css" type="text/css" media="screen" />
<?php } ?>
<script type="text/javascript">
function get()
{
$('#button').hide();
$('#wait').show();
$.post('dataflats3.php', {name : name.value},
function(output){
$('#more').html(output).show();
$('#wait').hide();
});
}
</script>
<style type="text/css">
div#wait
{
background:url('images/wait.gif');
width:28px;
height:28px;
display:none;
margin-left:320px;
margin-top:40px;
}
div#result
{
text-align:right;
float:right;
}
</style>
<?php include("include/header.php"); ?>
<div id="firstd"> </div>
<div id="middle">
<?php
$result=$mysqli->query("SELECT * FROM flats3 ORDER by id DESC LIMIT 5")or die($mysqli->error);
while($row=$result->fetch_array())
{
echo "<div id='title'> <span class='t'>". $row['1']."</span></div><br/><br/>";
?>
<?php
echo "<div id='content'>";
echo substr($row['2'], 0, 450);
echo "<a href='details.php?id=".$row['0']."'><div class='more'>..الـمـزيـد</div></a><br/><br/><br/>";
echo "</div>";
}
?>
<div id="more">
</div>
<?php
$result1 = $mysqli->query("SELECT title, content FROM flats3")or die($mysqli->error);
$numRows = $result1->num_rows;
if($numRows>5)
{
echo " <form id='form' name='form'>";
echo "<div id='wait'> </div> <input type='button' id='button' style='border:none; margin-right:250px; margin-top:30px; background:url(images/seemore.png); float:right; width:334px; height:34px; ' name='name' onClick='get();'>";
echo "</form>";
}
elseif($numRows==0)
{
echo "<div style='text-align:center;'>"." لاتوجد عروض متاحة إلى الآن"."</div>";
}
?>
</div>
<div id="last"> </div>
<?php include("include/footer.php"); ?>
</body>
</html>