$val0) { echo ' '; } echo '
'; echo '
Проверить баланс
'; $mainid = array(); $result = dbq('SELECT a.*, b.pretty_url AS caturl, b.name AS catname FROM '.$dbtable['news'].' a LEFT JOIN '.$dbtable['newscat'].' b ON (b.id=a.id_cat) WHERE a.status="1" AND a.ismain="1" AND a.cdate<="'.$nowsqldate.' 23:59:59" ORDER BY a.cdate DESC, a.id DESC LIMIT 1'); while ($r = mysql_fetch_assoc($result)) { $mainid[] = $r['id']; $link = getnewslink($r); $img = findsingleimage('inews_', $r['id']); if ($img) { $imgsrc = resize_image($img, 600, 250, false, false, false); } echo '
'.($imgsrc ? '
' : '').'
'.date_select($r['cdate'],-3,'','y-m-d').'

'.vparse($r['name']).'

'.vparse($r['descr']).'

Все новости
'; } $limit = intval($xoptions['mv_news']); $life = ($xoptions['mv_newslife'] ? $xoptions['mv_newslife'] : 60); if ($limit) { $query = "SELECT a.*, b.pretty_url AS caturl, b.name AS catname FROM ".$dbtable['news']." a LEFT JOIN ".$dbtable['newscat']." b ON (b.id=a.id_cat) WHERE a.status='1' AND a.cdate<='".$nowsqldate." 23:59:59' AND a.cdate >= DATE_SUB('".$nowsqldate." 00:00:00', INTERVAL ".$life." DAY) ".($mainid ? ' AND a.id NOT IN ('.implode(',', $mainid).')' : '')." ORDER BY a.cdate DESC, a.id DESC LIMIT ".$limit; $result = dbq($query); if (mysql_num_rows($result)) { echo ''; } } $res = dbq('SELECT * FROM '.$dbtable['cards'].' ORDER BY priority'); if (mysql_num_rows($res)){ echo '

Оплачивать - удобно, пользоваться - приятно

    '; while ($arr = mysql_fetch_assoc($res)) { $img = findsingleimage('card_', $arr['id']); list(,,,$attr) = getimagesize($site['path'].$img); if ($attr){ echo '
  • '.vparse($arr['name']).'

  • '; } } echo '
'; } echo '
'; p_bottom('index'); p_final(); ?>