<table width="100%" cellpadding="0" cellspacing="0" style="margin-top:-10px;" >
<tr valign="top">
<td width="75%" valign="top">
<?
if($id_catalog)
{
$azmm='publication';
?>
<table width=100% cellpadding="0" cellspacing="0"><tr><td class="tb4">
<?
echo '<a class="ww" href="'.$bp.$azmm.'/">Все публикации</a> ';
for ($i=1; $i<count($tree_cat); $i++)
{
if($tree_cat[$i])
{
if($i==(count($tree_cat)-1))
{
if(!$nav_spn)
echo ' / '.$arr_razdel[$tree_cat[($i-1)]][$tree_cat[$i]];
else
echo ' / <a class="ww" href="'.$bp.$azmm.'/'.$arr_razdel_url[$tree_cat[($i-1)]][$tree_cat[$i]].'_'.$tree_cat[$i].'/">'.$arr_razdel[$tree_cat[($i-1)]][$tree_cat[$i]].'</a> ';
}
else
echo ' / <a class="ww" href="'.$bp.$azmm.'/'.$arr_razdel_url[$tree_cat[($i-1)]][$tree_cat[$i]].'_'.$tree_cat[$i].'/">'.$arr_razdel[$tree_cat[($i-1)]][$tree_cat[$i]].'</a> ';
}
}
?>
</td></tr></table>
<?
}
$maxRows_Recordset1=$rru['ob_na_str'];
$pn = 0;
if (isset($_GET['pn']))
{
$pn = intval($_GET['pn']);
}
$uri=$_SERVER['REQUEST_URI'];
$uri=str_replace("&pn=".$pn, "", $uri);
$uri=str_replace("param_pn=".$pn, "", $uri);
$uri=str_replace("%5B", "[", $uri);
$uri=str_replace("%5D", "]", $uri);
$zmm='/publication/';
$uri2=explode("param_", $uri);
$zapros_q = $rzd2;
if($id_region)
$zapros_q .= '&'.$rgn2;
if(trim($uri2[1]))
$zapros_q .= '&'.trim($uri2[1]);
?>
<script type="text/javascript">
document.getElementById('zapros_q').value = '<?=$zapros_q?>';
</script>
<?
$startRow_Recordset1 = $pn * $maxRows_Recordset1;
$query_limit_Recordset1 = sprintf("%s LIMIT %d, %d", $query, $startRow_Recordset1, $maxRows_Recordset1);
$Recordset1 = mysql_query($query_limit_Recordset1, $connect) or die(mysql_error());
$row_Recordset1 = mysql_fetch_array($Recordset1);
if($query_group==1)
{
$rm = mysql_query($query_count);
if($rm)
{
$totalRows_Recordset1=0;
if($arr_catalog['catalog'])
{
$zamena = $zmm.$arr_catalog['url'].'_'.$arr_catalog['id_catalog'];
}
else
{
$zamena = $zmm;
$zamena_2 = '/';
}
echo '<table width=100% cellpadding="2" cellspacing="2">';
$i=0;
while ($rrm = mysql_fetch_array($rm))
{
if(!$i) echo '<tr valign=top>';
echo '<td width=33%>';
echo '<a href="'.(str_replace($zamena, $zmm.$arr_razdel_url[intval($id_catalog)][$rrm[1]].'_'.$rrm[1].$zamena_2, $uri)).'">'.$arr_razdel[intval($id_catalog)][$rrm[1]].'</a><span style="color:#858585"> </span><br>';
$totalRows_Recordset1 = $totalRows_Recordset1+$rrm[0];
$i++;
if($i==3) $i=0;
}
echo '</table><p>';
}
}
else
{
$all_Recordset1 = mysql_query($query_count);
$arr_query_count = mysql_fetch_array($all_Recordset1);
$totalRows_Recordset1 = $arr_query_count[0];
}
$totalPages_Recordset1 = ceil($totalRows_Recordset1/$maxRows_Recordset1)-1;
echo '<div id="len_t"></div>';
//echo ' Найдено записей: '.intval($totalRows_Recordset1);
if($totalRows_Recordset1)
{
echo '<br><br><TABLE width="100%" cellpadding="0" cellspacing="1" border="0">';
do
{
if (isset ($row_Recordset1['id']))
{
if($row_Recordset1['vip']) $vip_fon='bgcolor="#FFFFCA"'; else $vip_fon=''; /////////////////// VIP FON
echo '<tr data-href="'.$bp.'items_pub/'.$row_Recordset1['zag_url'].'_'.$row_Recordset1['id'].'"><td '.$vip_fon.'><table width="100%" cellpadding="5" cellspacing="5" >';
echo '<tr valign=top height="100" >';
echo '<td width="50">';
if(date($date_format_site, strtotime($row_Recordset1['data'])) == date($date_format_site))
echo 'Сегодня';
elseif(date($date_format_site, (strtotime($row_Recordset1['data']) + 24*60*60)) == date($date_format_site))
echo 'Вчера';
else
echo dat_rus($row_Recordset1['data'], 1);
//echo date("d-m", strtotime($row_Recordset1['data']));
echo '<br><span style="color:#858585">'.date("H:i", strtotime($row_Recordset1['data'])).'</span>';
echo '<td align=center valign=top width="100">';
if($row_Recordset1['small'])
// echo '<img class="imground" src="'.$bp.$row_Recordset1['small'].'" border=0>';
// elseif ($row_Recordset1['video_host'] == 'youtu.be' || $row_Recordset1['video_host']=='youtube.com')
echo '<img class="imground" width=100 src="http://i.ytimg.com/vi/'.$row_Recordset1['video_item'].'/1.jpg" border=0>';
//else echo '<img class="imground" src="'.$bp.'icon/nophoto_small.png" border=0>';
echo '<td width="70%">';
echo '<a style="font-size:14px" href="'.$bp.'items_pub/'.$row_Recordset1['zag_url'].'_'.$row_Recordset1['id'].'" >'.$row_Recordset1['zag'].'</a>';
if($row_Recordset1['anons']) echo '<br>'.$row_Recordset1['anons'];
if($row_Recordset1['razdel'] && !$con_razdel)
echo '<br><span style="color:#858585">'.$row_Recordset1['razdel'].'</span>';
if($row_Recordset1['pols']==2)
echo '<br><span style="color:#858585">Компания</span>';
echo '<td>';
echo '</table>';
}
} while ($row_Recordset1 = mysql_fetch_array($Recordset1));
echo '</table>';
}
mysql_free_result($Recordset1);
$uris=explode("param_",$uri);
if($uris[1]) //есть параметы кроме pn
{
$dop2="&pn=";
$map1="&map=1";
$map2="&map=2";
}
else
{
$dop2="param_pn=";
$map1="param_map=1";
$map2="param_map=2";
}
pages(15, $totalPages_Recordset1, $pn, $uri, $dop2);
echo '</div>';
?>
</td>
<td valign="top" class="tdd" align="center">
<?
include_once($base_path.'blok/right_blok.php');
?>
</td>
</tr>
</table>