Code: Select all
<?
include('config.inc.php');
$sql = "select * from anunt_imob_io order by id desc";
$sel = mysql_query($sql);
?>
<html>
<head>
<meta http-equiv="Content-Language" content="en-us">
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<link rel="stylesheet" type="text/css" href="stil.php">
<title>New Page 1</title>
</head>
<body>
<script src="culoarebari.js"></script>
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="700">
<tr>
<td width="149" rowspan="3" valign="top">
<p align="center">
<img border="0" src="img/imob.gif" width="100" height="66"></td>
<td width="551" bgcolor="#E3EEF4">
<p align="center"><b><font face="Verdana" size="2">IMOBILIARE ::</font><font face="Verdana" size="2" color="#004080">
INCHIRIERI-OFERTE</font></b></td>
</tr>
<tr>
<td align="center">
<?
$id = 0;
$list = "SELECT * FROM anunt_imob_io ORDER BY id DESC";
$resursa = mysql_query($list);
$numar = mysql_num_rows($resursa);
if(!isset($page)){
$page=0;
$curent = $_GETї'page'];
$rest = $numar%$num_posts;
}
if($rest == "0"){
$pagini = $numar/$num_posts;
}
else
{
$pagini_dec = $numar/$num_posts;
$pagini_dec = explode(".",$pagini_dec);
$pagini = $pagini_decї0]+1;
}
if (($pagini*$num_posts) < $numar) {
$pagini++;
}
echo "<table align='center' width=100%>
<tr>
<td width=100% align=right>
<font face='Verdana' size=2>";
print ' '.$lang_pgs.'';
for ($x = 1; $x <= $pagini; $x++)
{
if($x == $curent) {
print ''.$x.'';
print " ";
} else {
print '<a class="page_nr" href="imob_io.php?page='.$x.'">'.$x.'</a>';
print " ";
}
}
print '</font></td></tr></table>';
?>
</td>
</tr>
<tr>
<td width="551">
<?
while ($rez = mysql_fetch_array($sel)) {
$corp = $rezї'corp'];
$corp1 = wordwrap($corp, 55, "\n", 1);
$corp1 = preg_replace('#(<)(ї\/]?.*?)(>)#is', "<\\2>", $corp1);
$id++;
if ($id>($curent-1)*$num_posts)
if ($id<=($curent*$num_posts))
{
echo "
<div align="center">
<center>
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="551">
<tr>
<td width="500" colspan="2"><hr></td>
</tr>
<tr>
<td width="500" colspan="2">
<p align="left"><font face="Arial" size="2">Anunt afisat de
<font color="#004080"><a href="mailto:".cenzura($rezї'email'])."?subject=In legatura cu anuntul dumneavoastra..." class="top">".cenzura($rezї'nume'])." ".cenzura($rezї'prenume'])."</a></font> la data
<font color="#004080"><b>".$rezї'zi_in'].".".$rezї'luna_in'].".".$rezї'an_in']."</b></font>. Expira la
<font color="#004080"><b>".$rezї'zi_out'].".".$rezї'luna_out'].".".$rezї'an_out']."</b></font></font></td>
</tr>
<tr>
<td width="69" align="center" valign="top" bgcolor="#004080">
<p style="margin-top: 0; margin-bottom: 0">
<font face="Arial" size="2" color="#ffffff">ID anunt</font></p>
<p style="margin-top: 0; margin-bottom: 0"><b>
<font face="Arial" size="2" color="#ffffff">".$rezї'anunt_id']."</font></b></td>
<td width="480" valign="top" bgcolor="#E3EEF4"><b>
<font face="Verdana" size="2">".cenzura($corp1)."</font></b></td>
</tr>
<tr>
<td width="71" align="center" valign="top"> </td>
<td width="480" valign="top">
<p style="margin-top: 0; margin-bottom: 0">
<font face="Arial" size="2">Relatii la telefon: <font color="#004080">
<b>".cenzura($rezї'tel'])."</b> </font>sau la</font></p>
<p style="margin-top: 0; margin-bottom: 0">
<font face="Arial" size="2">adresa: <b><font color="#004080">".cenzura($rezї'adres'])."</font></b></font></td>
</tr>
<tr>
<td width="551" align="center" valign="top" colspan="2"><hr></td>
</tr>
</table>
</center>
</div>";
}
}
?>
</td>
</tr>
</table>
</body>
</html>