На главную Главная | Цены на бензин, дизельное топливо и газ в Оренбурге
Добавить в каталог магазин, фирму, бутик, кафе, ресторан ...





Веб камеры Оренбурга



Партнеры портала

  Мастер на час (муж на час) - Россия, Оренбургская, Оренбург.

  ООО "Выставочный Центр ВЕТА" ТПП ВО - Россия, , Воронеж.

  000 «ТЦ Машиностроение» - Россия, , Оренбургская область, Кувандыкский район, п.Гумарово.

  Качественный ремонт квартир - Россия, , Оренбург.

  Представитель Росгосстрах- Анастасия - Россия, Оренбургская, Оренбург.




Популярные фирмы

  ООО "Торговый Дом "Ликосстальпром" - Россия, Оренбургская, Оренбург.

  (8348 Просмотров с 07-03-2013)

  Фотосалон "Marius" - Россия, , Оренбург.

  (8818 Просмотров с 07-27-2011)

  АГРОТЕХСЕРВИС - Россия, Оренбургская, Оренбург.

  (15342 Просмотров с 07-20-2011)

  Профессиональные психологические услуги в Оренбурге - Россия, Оренбургская, Оребург.

  (6054 Просмотров с 07-03-2013)

  Ремонт Котлов и Кондиционеров - Россия, Оренбургская, Оренбург.

  (2353 Просмотров с 07-04-2013)


 
Цены на бензин, дизельное топливо и газ в Оренбурге

<?php


/*$db_azs_group = $prefix_b.'_azs_group';
$db_azs_oil = $prefix_b."_azs_oil";*/

class b2aex{
    function get_num_text($number){
        if((floatval($number) === 0) || floatval($number) === 0.0 ){
            return '-';
        }else{
            return number_format(floatval($number), 2, ',', ' ');
        }
    }

    function get_num_text_ex($last, $first){
        $number = (float)($last) - (float)$first;
        // echo var_dump($last);
        //echo var_dump($first);
        $number = (float)number_format(floatval($number), 2, '.', ' ');

        if((floatval($number) === 0) || floatval($number) === 0.0 ){
            return number_format(floatval($number), 2, ',', ' ');
        }else{
            $a =  number_format(floatval($number), 2, ',', ' ');
        }

        if(floatval($number) >0)
            $ex = '+';

        return $ex.$a;
    }

    function get_num_key($number){
        return number_format(floatval($number), 2, '', '');
    }
}

$b2aex = new b2aex;
$incomingline_firm = "Цены на бензин, дизельное топливо и газ в Оренбурге";

$incomingline = "<a href="index.php">
                       <font color="$def_status_font_color">
                        <u>$def_catalogue</u>
                       </font>
                      </a> | <font color="$def_status_font_color">$incomingline_firm</font>";



include ( "./defaults.php" );
include ( "./template/$def_template/header.php" );

?>
<link media="screen" href="../includes/azs.css" type="text/css" rel="stylesheet" />
<script src="/includes/jquery.tablesorter.min.js"></script>
<?
$lAZS_O = $db->query ("
  SELECT ag.*, ao.*
  FROM ( SELECT * FROM $db_azs_oil AS o ORDER BY o.CREATED DESC ) AS ao
  LEFT JOIN $db_azs_group AS ag ON ag.ID = ao.PARENTID
  GROUP BY ao.PARENTID
");


?>
<h1 class="g-title">Цены на топливо в Оренбурге <span>на <?echo date('d.m.Y')?></span></h1>
<p>На этой странице размещается информация об АЗС и ценах на топливо в Оренбурге.

</p><p>Здесь вы найдете:

</p><ul>
<li>актуальные цены на многих АЗС (см. ниже на этой странице);
</li><li>статистику изменения цен на той или иной АЗС;
</li>
</ul>

<p>Информация о ценах и об АЗС добавляется как редакцией проекта, так и посетителями сайта, то есть и вы можете помочь проекту - сообщить о цене или прислать информацию об АЗС! <i>(это можно сделать сообщив на адрес <a href="mailto:oburg@oburg.ru">oburg@oburg.ru</a> или через <a href="contact.php">форму обратной связи</a>.)</i><br>


<script type="text/javascript"><!--
google_ad_client = "ca-pub-3307195503897664";
/* В новостях */
google_ad_slot = "0981641666";
google_ad_width = 468;
google_ad_height = 15;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>

<table class="b2a_list_oil">
<thead>
    <tr>
        <th class="b2a_name"><h3>АЗС</h3></th>
        <th><h3>АИ-92</h3></th>
        <th><h3>АИ-92+</h3></th>
        <th><h3>АИ-95</h3></th>
        <th><h3>АИ-95+</h3></th>
        <th><h3>АИ-98</h3></th>
        <th><h3>АИ-80</h3></th>
        <th><h3>Дз (з)</h3></th>
        <th><h3>Дз (л)</h3></th>
        <th><h3>Дз Евро-5</h3></th>
        <th><h3>Газ</h3></th>
    </tr>
</thead>
<tbody>
    <? while ($item = mysql_fetch_assoc($lAZS_O))  : ?>
    <tr>
        <td class="b2a_name"><?=!empty($item['LINK']) ? '<a href="'.$item['LINK'].'">' : '';?><?=$item['DESCR'];?><?=!empty($item['LINK']) ? '</a>' : '';?></td>
        <td class="AI_92" rel="<?=$b2aex->get_num_text($item['AI_92']);?>"><?=$b2aex->get_num_text($item['AI_92']);?></td>
        <td class="AI_92p" rel="<?=$b2aex->get_num_text($item['AI_92p']);?>"><?=$b2aex->get_num_text($item['AI_92p']);?></td>
        <td class="AI_95" rel="<?=$b2aex->get_num_text($item['AI_95']);?>"><?=$b2aex->get_num_text($item['AI_95']);?></td>
        <td class="AI_95p" rel="<?=$b2aex->get_num_text($item['AI_95p']);?>"><?=$b2aex->get_num_text($item['AI_95p']);?></td>
        <td class="AI_98" rel="<?=$b2aex->get_num_text($item['AI_98']);?>"><?=$b2aex->get_num_text($item['AI_98']);?></td>
        <td class="AI_80" rel="<?=$b2aex->get_num_text($item['AI_80']);?>"><?=$b2aex->get_num_text($item['AI_80']);?></td>
        <td class="DF_Z" rel="<?=$b2aex->get_num_text($item['DF_Z']);?>"><?=$b2aex->get_num_text($item['DF_Z']);?></td>
        <td class="DF_L" rel="<?=$b2aex->get_num_text($item['DF_L']);?>"><?=$b2aex->get_num_text($item['DF_L']);?></td>
        <td class="DZ_E" rel="<?=$b2aex->get_num_text($item['DZ_E']);?>"><?=$b2aex->get_num_text($item['DZ_E']);?></td>
        <td class="GAZ" rel="<?=$b2aex->get_num_text($item['GAZ']);?>"><?=$b2aex->get_num_text($item['GAZ']);?></td>
    </tr>
    <?  if((float)$item['AI_92'] > 0)
            $a_minVal_o['AI_92'][$b2aex->get_num_key($item['AI_92'])]    = (float)$item['AI_92'];
        if((float)$item['AI_92p'] > 0)
            $a_minVal_o['AI_92p'][$b2aex->get_num_key($item['AI_92p'])]    = (float)$item['AI_92p'];
        if((float)$item['AI_95'] > 0)
            $a_minVal_o['AI_95'][$b2aex->get_num_key($item['AI_95'])]    = (float)$item['AI_95'];
        if((float)$item['AI_95p'] > 0)
            $a_minVal_o['AI_95p'][$b2aex->get_num_key($item['AI_95p'])]    = (float)$item['AI_95p'];
        if((float)$item['AI_98'] > 0)
            $a_minVal_o['AI_98'][$b2aex->get_num_key($item['AI_98'])]    = (float)$item['AI_98'];
        if((float)$item['AI_80'] > 0)
            $a_minVal_o['AI_80'][$b2aex->get_num_key($item['AI_80'])]    = (float)$item['AI_80'];
        if((float)$item['DF_Z'] > 0)
            $a_minVal_o['DF_Z'][$b2aex->get_num_key($item['DF_Z'])]      = (float)$item['DF_Z'];
        if((float)$item['DF_L'] > 0)
            $a_minVal_o['DF_L'][$b2aex->get_num_key($item['DF_L'])]      = (float)$item['DF_L'];
        if((float)$item['DZ_E'] > 0)
            $a_minVal_o['DZ_E'][$b2aex->get_num_key($item['DZ_E'])]      = (float)$item['DZ_E'];
        if((float)$item['GAZ'] > 0)
            $a_minVal_o['GAZ'][$b2aex->get_num_key($item['GAZ'])]        = (float)$item['GAZ'];

        if((float)$item['AI_92'] > 0)
            $avgVal_o['AI_92'] = (isset($avgVal_o['AI_92']) ? $avgVal_o['AI_92'] : 0) + (float)$item['AI_92'];
        if((float)$item['AI_92p'] > 0)
            $avgVal_o['AI_92p'] = (isset($avgVal_o['AI_92p']) ? $avgVal_o['AI_92p'] : 0) + (float)$item['AI_92p'];
        if((float)$item['AI_95'] > 0)
            $avgVal_o['AI_95'] = (isset($avgVal_o['AI_95']) ? $avgVal_o['AI_95'] : 0) + (float)$item['AI_95'];
        if((float)$item['AI_95p'] > 0)
            $avgVal_o['AI_95p'] = (isset($avgVal_o['AI_95p']) ? $avgVal_o['AI_95p'] : 0) + (float)$item['AI_95p'];
        if((float)$item['AI_98'] > 0)
            $avgVal_o['AI_98'] = (isset($avgVal_o['AI_98']) ? $avgVal_o['AI_98'] : 0) + (float)$item['AI_98'];
        if((float)$item['AI_80'] > 0)
            $avgVal_o['AI_80'] = (isset($avgVal_o['AI_80']) ? $avgVal_o['AI_80'] : 0) + (float)$item['AI_80'];
        if((float)$item['DF_Z'] > 0)
            $avgVal_o['DF_Z']  = (isset($avgVal_o['DF_Z']) ? $avgVal_o['DF_Z'] : 0) + (float)$item['DF_Z'];
        if((float)$item['DF_L'] > 0)
            $avgVal_o['DF_L']  = (isset($avgVal_o['DF_L']) ? $avgVal_o['DF_L'] : 0) + (float)$item['DF_L'];
        if((float)$item['DZ_E'] > 0)
            $avgVal_o['DZ_E']  = (isset($avgVal_o['DZ_E']) ? $avgVal_o['DZ_E'] : 0) + (float)$item['DZ_E'];
        if((float)$item['GAZ'] > 0)
            $avgVal_o['GAZ']   = (isset($avgVal_o['GAZ']) ? $avgVal_o['GAZ'] : 0) + (float)$item['GAZ'];


        if((float)$item['AI_92'] > 0)
            $azs_iter_o['AI_92'] = isset($azs_iter_o['AI_92']) ? $azs_iter_o['AI_92'] + 1 : 1 ;
        if((float)$item['AI_92p'] > 0)
            $azs_iter_o['AI_92p'] = isset($azs_iter_o['AI_92p']) ? $azs_iter_o['AI_92p'] + 1 : 1 ;
        if((float)$item['AI_95'] > 0)
            $azs_iter_o['AI_95'] = isset($azs_iter_o['AI_95']) ? $azs_iter_o['AI_95'] + 1 : 1 ;
        if((float)$item['AI_95p'] > 0)
            $azs_iter_o['AI_95p'] = isset($azs_iter_o['AI_95p']) ? $azs_iter_o['AI_95p'] + 1 : 1 ;
        if((float)$item['AI_98'] > 0)
            $azs_iter_o['AI_98'] = isset($azs_iter_o['AI_98']) ? $azs_iter_o['AI_98'] + 1 : 1 ;
        if((float)$item['AI_80'] > 0)
            $azs_iter_o['AI_80'] = isset($azs_iter_o['AI_80']) ? $azs_iter_o['AI_80'] + 1 : 1 ;
        if((float)$item['DF_Z'] > 0)
            $azs_iter_o['DF_Z'] = isset($azs_iter_o['DF_Z']) ? $azs_iter_o['DF_Z'] + 1 : 1 ;
        if((float)$item['DF_L'] > 0)
            $azs_iter_o['DF_L'] = isset($azs_iter_o['DF_L']) ? $azs_iter_o['DF_L'] + 1 : 1 ;
        if((float)$item['DZ_E'] > 0)
            $azs_iter_o['DZ_E'] = isset($azs_iter_o['DZ_E']) ? $azs_iter_o['DZ_E'] + 1 : 1 ;

        if((float)$item['GAZ'] > 0)
            $azs_iter_o['GAZ'] = isset($azs_iter_o['GAZ']) ? $azs_iter_o['GAZ'] + 1 : 1 ;

        $dateex_o[$item['PARENTID']] = "`o`.`CREATED` <> '".date('Y-m-d',strtotime($item['CREATED']))."'";
    ?>
    <? endwhile; unset($item, $lAZS_O);?>
    <?
        if(is_array($dateex_o)){
            $llAZS = $db->query ("
              SELECT ag.*, ao.*
              FROM ( SELECT * FROM $db_azs_oil AS o WHERE (".implode(' AND',$dateex_o).") ORDER BY o.CREATED DESC) AS ao
              LEFT JOIN $db_azs_group AS ag ON ag.ID = ao.PARENTID
              GROUP BY ao.PARENTID
            ");

            while ($item = mysql_fetch_assoc($llAZS))  {
                if((float)$item['AI_92'] > 0)
                    $b_minVal_o['AI_92'][$b2aex->get_num_key($item['AI_92'])]    = (float)$item['AI_92'];
                if((float)$item['AI_92p'] > 0)
                    $b_minVal_o['AI_92p'][$b2aex->get_num_key($item['AI_92p'])]    = (float)$item['AI_92p'];
                if((float)$item['AI_95'] > 0)
                    $b_minVal_o['AI_95'][$b2aex->get_num_key($item['AI_95'])]    = (float)$item['AI_95'];
                if((float)$item['AI_95p'] > 0)
                    $b_minVal_o['AI_95p'][$b2aex->get_num_key($item['AI_95p'])]    = (float)$item['AI_95p'];
                if((float)$item['AI_98'] > 0)
                    $b_minVal_o['AI_98'][$b2aex->get_num_key($item['AI_98'])]    = (float)$item['AI_98'];
                if((float)$item['AI_80'] > 0)
                    $b_minVal_o['AI_80'][$b2aex->get_num_key($item['AI_80'])]    = (float)$item['AI_80'];
                if((float)$item['DF_Z'] > 0)
                    $b_minVal_o['DF_Z'][$b2aex->get_num_key($item['DF_Z'])]      = (float)$item['DF_Z'];
                if((float)$item['DF_L'] > 0)
                    $b_minVal_o['DF_L'][$b2aex->get_num_key($item['DF_L'])]      = (float)$item['DF_L'];
                if((float)$item['DZ_E'] > 0)
                    $b_minVal_o['DZ_E'][$b2aex->get_num_key($item['DZ_E'])]      = (float)$item['DZ_E'];
                if((float)$item['GAZ'] > 0)
                    $b_minVal_o['GAZ'][$b2aex->get_num_key($item['GAZ'])]        = (float)$item['GAZ'];

                if((float)$item['AI_92'] > 0)
                    $bavgVal_o['AI_92'] = (isset($bavgVal_o['AI_92']) ? $bavgVal_o['AI_92'] : 0) + (float)$item['AI_92'];
                if((float)$item['AI_92p'] > 0)
                    $bavgVal_o['AI_92p'] = (isset($bavgVal_o['AI_92p']) ? $bavgVal_o['AI_92p'] : 0) + (float)$item['AI_92p'];
                if((float)$item['AI_95'] > 0)
                    $bavgVal_o['AI_95'] = (isset($bavgVal_o['AI_95']) ? $bavgVal_o['AI_95'] : 0) + (float)$item['AI_95'];
                if((float)$item['AI_95p'] > 0)
                    $bavgVal_o['AI_95p'] = (isset($bavgVal_o['AI_95p']) ? $bavgVal_o['AI_95p'] : 0) + (float)$item['AI_95p'];
                if((float)$item['AI_98'] > 0)
                    $bavgVal_o['AI_98'] = (isset($bavgVal_o['AI_98']) ? $bavgVal_o['AI_98'] : 0) + (float)$item['AI_98'];
                if((float)$item['AI_80'] > 0)
                    $bavgVal_o['AI_80'] = (isset($bavgVal_o['AI_80']) ? $bavgVal_o['AI_80'] : 0) + (float)$item['AI_80'];
                if((float)$item['DF_Z'] > 0)
                    $bavgVal_o['DF_Z']  = (isset($bavgVal_o['DF_Z']) ? $bavgVal_o['DF_Z'] : 0) + (float)$item['DF_Z'];
                if((float)$item['DF_L'] > 0)
                    $bavgVal_o['DF_L']  = (isset($bavgVal_o['DF_L']) ? $bavgVal_o['DF_L'] : 0) + (float)$item['DF_L'];
                if((float)$item['DZ_E'] > 0)
                    $bavgVal_o['DZ_E']  = (isset($bavgVal_o['DZ_E']) ? $bavgVal_o['DZ_E'] : 0) + (float)$item['DZ_E'];
                if((float)$item['GAZ'] > 0)
                    $bavgVal_o['GAZ']   = (isset($bavgVal_o['GAZ']) ? $bavgVal_o['GAZ'] : 0) + (float)$item['GAZ'];


                if((float)$item['AI_92'] > 0)
                    $iter_o['AI_92'] = isset($iter_o['AI_92']) ? $iter_o['AI_92'] + 1 : 1 ;
                if((float)$item['AI_92p'] > 0)
                    $iter_o['AI_92p'] = isset($iter_o['AI_92p']) ? $iter_o['AI_92p'] + 1 : 1 ;
                if((float)$item['AI_95'] > 0)
                    $iter_o['AI_95'] = isset($iter_o['AI_95']) ? $iter_o['AI_95'] + 1 : 1 ;
                if((float)$item['AI_95p'] > 0)
                    $iter_o['AI_95p'] = isset($iter_o['AI_95p']) ? $iter_o['AI_95p'] + 1 : 1 ;
                if((float)$item['AI_98'] > 0)
                    $iter_o['AI_98'] = isset($iter_o['AI_98']) ? $iter_o['AI_98'] + 1 : 1 ;
                if((float)$item['AI_80'] > 0)
                    $iter_o['AI_80'] = isset($iter_o['AI_80']) ? $iter_o['AI_80'] + 1 : 1 ;
                if((float)$item['DF_Z'] > 0)
                    $iter_o['DF_Z'] = isset($iter_o['DF_Z']) ? $iter_o['DF_Z'] + 1 : 1 ;
                if((float)$item['DF_L'] > 0)
                    $iter_o['DF_L'] = isset($iter_o['DF_L']) ? $iter_o['DF_L'] + 1 : 1 ;
                if((float)$item['DZ_E'] > 0)
                    $iter_o['DZ_E'] = isset($iter_o['DZ_E']) ? $iter_o['DZ_E'] + 1 : 1 ;
                if((float)$item['GAZ'] > 0)
                    $iter_o['GAZ'] = isset($iter_o['GAZ']) ? $iter_o['GAZ'] + 1 : 1 ;
            }

            if(is_array($b_minVal_o['AI_92']))
                ksort($b_minVal_o['AI_92']);
            unset($b_minVal_o['AI_92'][0]);
            $b_minVal_o['AI_92'][0] = 0;

            $bminVal_o['AI_92'] = array_shift($b_minVal_o['AI_92']);

            if(is_array($b_minVal_o['AI_92p']))
                ksort($b_minVal_o['AI_92p']);
            unset($b_minVal_o['AI_92p'][0]);
            $b_minVal_o['AI_92p'][0] = 0;

            $bminVal_o['AI_92p'] = array_shift($b_minVal_o['AI_92p']);

            if(is_array($b_minVal_o['AI_95']))
                ksort($b_minVal_o['AI_95']);
            unset($b_minVal_o['AI_95'][0]);
            $b_minVal_o['AI_95'][0] = 0;
            $bminVal_o['AI_95'] = array_shift($b_minVal_o['AI_95']);

            if(is_array($b_minVal_o['AI_95p']))
                ksort($b_minVal_o['AI_95p']);
            unset($b_minVal_o['AI_95p'][0]);
            $b_minVal_o['AI_95p'][0] = 0;

            $bminVal_o['AI_95p'] = array_shift($b_minVal_o['AI_95p']);

            if(is_array($b_minVal_o['AI_98']))
                ksort($b_minVal_o['AI_98']);
            unset($b_minVal_o['AI_98'][0]);
            $b_minVal_o['AI_98'][0] = 0;
            $bminVal_o['AI_98'] = array_shift($b_minVal_o['AI_98']);

            if(is_array($b_minVal_o['AI_80']))
                ksort($b_minVal_o['AI_80']);
            unset($b_minVal_o['AI_80'][0]);
            $b_minVal_o['AI_80'][0] = 0;
            $bminVal_o['AI_80'] = array_shift($b_minVal_o['AI_80']);


            if(is_array($b_minVal_o['DF_Z']))
                ksort($b_minVal_o['DF_Z']);
            unset($b_minVal_o['DF_Z'][0]);
            $b_minVal_o['DF_Z'][0] = 0;
            $bminVal_o['DF_Z'] = array_shift($b_minVal_o['DF_Z']);

            if(is_array($b_minVal_o['DF_L']))
                ksort($b_minVal_o['DF_L']);
            unset($b_minVal_o['DF_L'][0]);
            $b_minVal_o['DF_L'][0] = 0;
            $bminVal_o['DF_L'] = array_shift($b_minVal_o['DF_L']);

            if(is_array($b_minVal_o['DZ_E']))
                ksort($b_minVal_o['DZ_E']);
            unset($b_minVal_o['DZ_E'][0]);
            $b_minVal_o['DZ_E'][0] = 0;
            $bminVal_o['DZ_E'] = array_shift($b_minVal_o['DZ_E']);

            if(is_array($b_minVal_o['GAZ']))
                ksort($b_minVal_o['GAZ']);;
            unset($b_minVal_o['GAZ'][0]);
            $b_minVal_o['GAZ'][0] = 0;
            $bminVal_o['GAZ'] = array_shift($b_minVal_o['GAZ']);

            $bavgVal_o['AI_92'] = $bavgVal_o['AI_92'] / (($iter_o['AI_92'])>0 ? ($iter_o['AI_92']) : 1);
            $bavgVal_o['AI_92p'] = $bavgVal_o['AI_92p'] / (($iter_o['AI_92p'])>0 ? ($iter_o['AI_92p']) : 1);
            $bavgVal_o['AI_95'] = $bavgVal_o['AI_95'] / (($iter_o['AI_95'])>0 ? ($iter_o['AI_95']) : 1);
            $bavgVal_o['AI_95p'] = $bavgVal_o['AI_95p'] / (($iter_o['AI_95p'])>0 ? ($iter_o['AI_95p']) : 1);
            $bavgVal_o['AI_98'] = $bavgVal_o['AI_98'] / (($iter_o['AI_98'])>0 ? ($iter_o['AI_98']) : 1);
            $bavgVal_o['AI_80'] = $bavgVal_o['AI_80'] / (($iter_o['AI_80'])>0 ? ($iter_o['AI_80']) : 1);
            $bavgVal_o['DF_Z']  = $bavgVal_o['DF_Z'] / (($iter_o['DF_Z'])>0 ? ($iter_o['DF_Z']) : 1);
            $bavgVal_o['DF_L']  = $bavgVal_o['DF_L'] / (($iter_o['DF_L'])>0 ? ($iter_o['DF_L']) : 1);
            $bavgVal_o['DZ_E']  = $bavgVal_o['DZ_E'] / (($iter_o['DZ_E'])>0 ? ($iter_o['DZ_E']) : 1);
            $bavgVal_o['GAZ']   = $bavgVal_o['GAZ'] / (($iter_o['GAZ'])>0 ? ($iter_o['GAZ']) : 1);

        }
        //
        if(is_array($a_minVal_o['AI_92']))
            ksort($a_minVal_o['AI_92']);
        unset($a_minVal_o['AI_92'][0]);
        $a_minVal_o['AI_92'][0] = 0;

        $minVal_o['AI_92'] = array_shift($a_minVal_o['AI_92']);

        if(is_array($a_minVal_o['AI_92p']))
            ksort($a_minVal_o['AI_92p']);
        unset($a_minVal_o['AI_92p'][0]);
        $a_minVal_o['AI_92p'][0] = 0;

        $minVal_o['AI_92p'] = array_shift($a_minVal_o['AI_92p']);

        if(is_array($a_minVal_o['AI_95']))
            ksort($a_minVal_o['AI_95']);
        unset($a_minVal_o['AI_95'][0]);
        $a_minVal_o['AI_95'][0] = 0;
        $minVal_o['AI_95'] = array_shift($a_minVal_o['AI_95']);

        if(is_array($a_minVal_o['AI_95p']))
            ksort($a_minVal_o['AI_95p']);
        unset($a_minVal_o['AI_95p'][0]);
        $a_minVal_o['AI_95p'][0] = 0;

        $minVal_o['AI_95p'] = array_shift($a_minVal_o['AI_95p']);

        if(is_array($a_minVal_o['AI_98']))
            ksort($a_minVal_o['AI_98']);
        unset($a_minVal_o['AI_98'][0]);
        $a_minVal_o['AI_98'][0] = 0;
        $minVal_o['AI_98'] = array_shift($a_minVal_o['AI_98']);

        if(is_array($a_minVal_o['AI_80']))
            ksort($a_minVal_o['AI_80']);
        unset($a_minVal_o['AI_80'][0]);
        $a_minVal_o['AI_80'][0] = 0;
        $minVal_o['AI_80'] = array_shift($a_minVal_o['AI_80']);


        if(is_array($a_minVal_o['DF_Z']))
            ksort($a_minVal_o['DF_Z']);
        unset($a_minVal_o['DF_Z'][0]);
        $a_minVal_o['DF_Z'][0] = 0;
        $minVal_o['DF_Z'] = array_shift($a_minVal_o['DF_Z']);

        if(is_array($a_minVal_o['DF_L']))
            ksort($a_minVal_o['DF_L']);
        unset($a_minVal_o['DF_L'][0]);
        $a_minVal_o['DF_L'][0] = 0;
        $minVal_o['DF_L'] = array_shift($a_minVal_o['DF_L']);

        if(is_array($a_minVal_o['DZ_E']))
            ksort($a_minVal_o['DZ_E']);
        unset($a_minVal_o['DZ_E'][0]);
        $a_minVal_o['DZ_E'][0] = 0;
        $minVal_o['DZ_E'] = array_shift($a_minVal_o['DZ_E']);

        if(is_array($a_minVal_o['GAZ']))
            ksort($a_minVal_o['GAZ']);;
        unset($a_minVal_o['GAZ'][0]);
        $a_minVal_o['GAZ'][0] = 0;
        $minVal_o['GAZ'] = array_shift($a_minVal_o['GAZ']);

        $avgVal_o['AI_92'] = $avgVal_o['AI_92'] / (($azs_iter_o['AI_92'])>0 ? ($azs_iter_o['AI_92']) : 1);
        $avgVal_o['AI_92p'] = $avgVal_o['AI_92p'] / (($azs_iter_o['AI_92p'])>0 ? ($azs_iter_o['AI_92p']) : 1);
        $avgVal_o['AI_95'] = $avgVal_o['AI_95'] / (($azs_iter_o['AI_95'])>0 ? ($azs_iter_o['AI_95']) : 1);
        $avgVal_o['AI_95p'] = $avgVal_o['AI_95p'] / (($azs_iter_o['AI_95p'])>0 ? ($azs_iter_o['AI_95p']) : 1);
        $avgVal_o['AI_98'] = $avgVal_o['AI_98'] / (($azs_iter_o['AI_98'])>0 ? ($azs_iter_o['AI_98']) : 1);
        $avgVal_o['AI_80'] = $avgVal_o['AI_80'] / (($azs_iter_o['AI_80'])>0 ? ($azs_iter_o['AI_80']) : 1);
        $avgVal_o['DF_Z']  = $avgVal_o['DF_Z'] / (($azs_iter_o['DF_Z'])>0 ? ($azs_iter_o['DF_Z']) : 1);
        $avgVal_o['DF_L']  = $avgVal_o['DF_L'] / (($azs_iter_o['DF_L'])>0 ? ($azs_iter_o['DF_L']) : 1);
        $avgVal_o['DZ_E']  = $avgVal_o['DZ_E'] / (($azs_iter_o['DZ_E'])>0 ? ($azs_iter_o['DZ_E']) : 1);
        $avgVal_o['GAZ']   = $avgVal_o['GAZ'] / (($azs_iter_o['GAZ'])>0 ? ($azs_iter_o['GAZ']) : 1);


        $bminVal_o['AI_92'] = $bminVal_o['AI_92'] == 0 ? $minVal_o['AI_92'] : $bminVal_o['AI_92'];
        $bminVal_o['AI_92p'] = $bminVal_o['AI_92p'] == 0 ? $minVal_o['AI_92p'] : $bminVal_o['AI_92p'];
        $bminVal_o['AI_95'] = $bminVal_o['AI_95'] == 0 ? $minVal_o['AI_95'] : $bminVal_o['AI_95'];
        $bminVal_o['AI_95p'] = $bminVal_o['AI_95p'] == 0 ? $minVal_o['AI_95p'] : $bminVal_o['AI_95p'];
        $bminVal_o['AI_98'] = $bminVal_o['AI_98'] == 0 ? $minVal_o['AI_98'] : $bminVal_o['AI_98'];
        $bminVal_o['AI_80'] = $bminVal_o['AI_80'] == 0 ? $minVal_o['AI_80'] : $bminVal_o['AI_80'];
        $bminVal_o['DF_Z'] = $bminVal_o['DF_Z'] == 0 ? $minVal_o['DF_Z'] : $bminVal_o['DF_Z'];
        $bminVal_o['DF_L'] = $bminVal_o['DF_L'] == 0 ? $minVal_o['DF_L'] : $bminVal_o['DF_L'];
        $bminVal_o['DZ_E'] = $bminVal_o['DZ_E'] == 0 ? $minVal_o['DZ_E'] : $bminVal_o['DZ_E'];
        $bminVal_o['GAZ'] = $bminVal_o['GAZ'] == 0 ? $minVal_o['GAZ'] : $bminVal_o['GAZ'];


        $bavgVal_o['AI_92'] = $bavgVal_o['AI_92'] == 0 ? $avgVal_o['AI_92'] : $bavgVal_o['AI_92'];
        $bavgVal_o['AI_92p'] = $bavgVal_o['AI_92p'] == 0 ? $avgVal_o['AI_92p'] : $bavgVal_o['AI_92p'];
        $bavgVal_o['AI_95'] = $bavgVal_o['AI_95'] == 0 ? $avgVal_o['AI_95'] : $bavgVal_o['AI_95'];
        $bavgVal_o['AI_95p'] = $bavgVal_o['AI_95p'] == 0 ? $avgVal_o['AI_95p'] : $bavgVal_o['AI_95p'];
        $bavgVal_o['AI_98'] = $bavgVal_o['AI_98'] == 0 ? $avgVal_o['AI_98'] : $bavgVal_o['AI_98'];
        $bavgVal_o['AI_80'] = $bavgVal_o['AI_80'] == 0 ? $avgVal_o['AI_80'] : $bavgVal_o['AI_80'];
        $bavgVal_o['DF_Z'] = $bavgVal_o['DF_Z'] == 0 ? $avgVal_o['DF_Z'] : $bavgVal_o['DF_Z'];
        $bavgVal_o['DF_L'] = $bavgVal_o['DF_L'] == 0 ? $avgVal_o['DF_L'] : $bavgVal_o['DF_L'];
        $bavgVal_o['DZ_E'] = $bavgVal_o['DZ_E'] == 0 ? $avgVal_o['DZ_E'] : $bavgVal_o['DZ_E'];
        $bavgVal_o['GAZ'] = $bavgVal_o['GAZ'] == 0 ? $avgVal_o['GAZ'] : $bavgVal_o['GAZ'];




    ?>
</tbody>
<tfoot>
    <tr class="total best">
        <td class="b2a_name">Лучшая цена</td>
        <td class="AI_92">
            <span><?=$b2aex->get_num_text($minVal_o['AI_92']);?></span>
            <p><?=$b2aex->get_num_text_ex($minVal_o['AI_92'], $bminVal_o['AI_92']);?></p>
        </td>
        <td class="AI_92p">
            <span><?=$b2aex->get_num_text($minVal_o['AI_92p']);?></span>
            <p><?=$b2aex->get_num_text_ex($minVal_o['AI_92p'], $bminVal_o['AI_92p']);?></p>
        </td>
        <td class="AI_95">
            <span><?=$b2aex->get_num_text($minVal_o['AI_95']);?></span>
            <p><?=$b2aex->get_num_text_ex($minVal_o['AI_95'], $bminVal_o['AI_95']);?></p>
        </td>
        <td class="AI_95p">
            <span><?=$b2aex->get_num_text($minVal_o['AI_95p']);?></span>
            <p><?=$b2aex->get_num_text_ex($minVal_o['AI_95p'], $bminVal_o['AI_95p']);?></p>
        </td>
        <td class="AI_98">
            <span><?=$b2aex->get_num_text($minVal_o['AI_98']);?></span>
            <p><?=$b2aex->get_num_text_ex($minVal_o['AI_98'],$bminVal_o['AI_98']);?></p>
        </td>
        <td class="AI_80">
            <span><?=$b2aex->get_num_text($minVal_o['AI_80']);?></span>
            <p><?=$b2aex->get_num_text_ex($minVal_o['AI_80'],$bminVal_o['AI_80']);?></p>
        </td>
        <td class="DF_Z">
            <span><?=$b2aex->get_num_text($minVal_o['DF_Z']);?></span>
            <p><?=$b2aex->get_num_text_ex($minVal_o['DF_Z'],$bminVal_o['DF_Z']);?></p>
        </td>
        <td class="DF_L">
            <span><?=$b2aex->get_num_text($minVal_o['DF_L']);?></span>
            <p><?=$b2aex->get_num_text_ex($minVal_o['DF_L'],$bminVal_o['DF_L']);?></p>
        </td>
        <td class="DZ_E">
            <span><?=$b2aex->get_num_text($minVal_o['DZ_E']);?></span>
            <p><?=$b2aex->get_num_text_ex($minVal_o['DZ_E'],$bminVal_o['DZ_E']);?></p>
        </td>
        <td class="GAZ">
            <span><?=$b2aex->get_num_text($minVal_o['GAZ']);?></span>
            <p><?=$b2aex->get_num_text_ex($minVal_o['GAZ'], $bminVal_o['GAZ']);?></p>
        </td>
    </tr>
    <tr class="total avg">
        <td class="b2a_name">Средняя цена</td>
        <td>
            <span><?=$b2aex->get_num_text($avgVal_o['AI_92']);?></span>
            <p><?=$b2aex->get_num_text_ex($avgVal_o['AI_92'],$bavgVal_o['AI_92']);?></p>
        </td>
        <td>
            <span><?=$b2aex->get_num_text($avgVal_o['AI_92p']);?></span>
            <p><?=$b2aex->get_num_text_ex($avgVal_o['AI_92p'],$bavgVal_o['AI_92p']);?></p>
        </td>
        <td>
            <span><?=$b2aex->get_num_text($avgVal_o['AI_95']);?></span>
            <p><?=$b2aex->get_num_text_ex($avgVal_o['AI_95'], $bavgVal_o['AI_95']);?></p>
        </td>
        <td>
            <span><?=$b2aex->get_num_text($avgVal_o['AI_95p']);?></span>
            <p><?=$b2aex->get_num_text_ex($avgVal_o['AI_95p'], $bavgVal_o['AI_95p']);?></p>
        </td>
        <td>
            <span><?=$b2aex->get_num_text($avgVal_o['AI_98']);?></span>
            <p><?=$b2aex->get_num_text_ex($avgVal_o['AI_98'],$bavgVal_o['AI_98']);?></p>
        </td>
        <td>
            <span><?=$b2aex->get_num_text($avgVal_o['AI_80']);?></span>
            <p><?=$b2aex->get_num_text_ex($avgVal_o['AI_80'],$bavgVal_o['AI_80']);?></p>
        </td>
        <td>
            <span><?=$b2aex->get_num_text($avgVal_o['DF_Z']);?></span>
            <p><?=$b2aex->get_num_text_ex($avgVal_o['DF_Z'],$bavgVal_o['DF_Z']);?></p>
        </td>
        <td>
            <span><?=$b2aex->get_num_text($avgVal_o['DF_L']);?></span>
            <p><?=$b2aex->get_num_text_ex($avgVal_o['DF_L'],$bavgVal_o['DF_L']);?></p>
        </td>
        <td>
            <span><?=$b2aex->get_num_text($avgVal_o['DZ_E']);?></span>
            <p><?=$b2aex->get_num_text_ex($avgVal_o['DZ_E'],$bavgVal_o['DZ_E']);?></p>
        </td>
        <td>
            <span><?=$b2aex->get_num_text($avgVal_o['GAZ']);?></span>
            <p><?=$b2aex->get_num_text_ex($avgVal_o['GAZ'],$bavgVal_o['GAZ']);?></p>
        </td>
    </tr>
</tfoot>
</table>
<script type="text/javascript">
    $('table.b2a_list_oil>tbody>tr>td.AI_92[rel="'+$('table.b2a_list_oil>tfoot>tr>td.AI_92>span').html()+'"]').html(
            '<strong>' + $('table.b2a_list_oil>tfoot>tr>td.AI_92>span').html() + '</strong>'
    );
    $('table.b2a_list_oil>tbody>tr>td.AI_92p[rel="'+$('table.b2a_list_oil>tfoot>tr>td.AI_92p>span').html()+'"]').html(
            '<strong>' + $('table.b2a_list_oil>tfoot>tr>td.AI_92p>span').html() + '</strong>'
    );
    $('table.b2a_list_oil>tbody>tr>td.AI_95[rel="'+$('table.b2a_list_oil>tfoot>tr>td.AI_95>span').html()+'"]').html(
            '<strong>' + $('table.b2a_list_oil>tfoot>tr>td.AI_95>span').html() + '</strong>'
    );
    $('table.b2a_list_oil>tbody>tr>td.AI_95p[rel="'+$('table.b2a_list_oil>tfoot>tr>td.AI_95p>span').html()+'"]').html(
            '<strong>' + $('table.b2a_list_oil>tfoot>tr>td.AI_95p>span').html() + '</strong>'
    );
    $('table.b2a_list_oil>tbody>tr>td.AI_98[rel="'+$('table.b2a_list_oil>tfoot>tr>td.AI_98>span').html()+'"]').html(
            '<strong>' + $('table.b2a_list_oil>tfoot>tr>td.AI_98>span').html() + '</strong>'
    );
    $('table.b2a_list_oil>tbody>tr>td.AI_80[rel="'+$('table.b2a_list_oil>tfoot>tr>td.AI_80>span').html()+'"]').html(
            '<strong>' + $('table.b2a_list_oil>tfoot>tr>td.AI_80>span').html() + '</strong>'
    );
    $('table.b2a_list_oil>tbody>tr>td.DF_Z[rel="'+$('table.b2a_list_oil>tfoot>tr>td.DF_Z>span').html()+'"]').html(
            '<strong>' + $('table.b2a_list_oil>tfoot>tr>td.DF_Z>span').html() + '</strong>'
    );
    $('table.b2a_list_oil>tbody>tr>td.DF_L[rel="'+$('table.b2a_list_oil>tfoot>tr>td.DF_L>span').html()+'"]').html(
            '<strong>' + $('table.b2a_list_oil>tfoot>tr>td.DF_L>span').html() + '</strong>'
    );
    $('table.b2a_list_oil>tbody>tr>td.DZ_E[rel="'+$('table.b2a_list_oil>tfoot>tr>td.DZ_E>span').html()+'"]').html(
            '<strong>' + $('table.b2a_list_oil>tfoot>tr>td.DZ_E>span').html() + '</strong>'
    );
    $('table.b2a_list_oil>tbody>tr>td.GAZ[rel="'+$('table.b2a_list_oil>tfoot>tr>td.GAZ>span').html()+'"]').html(
            '<strong>' + $('table.b2a_list_oil>tfoot>tr>td.GAZ>span').html() + '</strong>'
    );

    $("table.b2a_list_oil").tablesorter();
</script>
<?
    unset($avgVal, $minVal, $iter, $a_minVal);
?>

<br><br><br>

<!-- Put this script tag to the <head> of your page -->
<script type="text/javascript" src="//vk.com/js/api/openapi.js?68"></script>

<script type="text/javascript">
  VK.init({apiId: 2748394, onlyWidgets: true});
</script>

<!-- Put this div tag to the place, where the Comments block will be -->
<div id="vk_comments"></div>
<script type="text/javascript">
VK.Widgets.Comments("vk_comments", {limit: 10, width: "496", attach: "*"});
</script>

<?php

include ( "./template/$def_template/footer.php" );

// ALTER TABLE `pmd_azs_oil` ADD `AI_92P` FLOAT NOT NULL DEFAULT '0' AFTER `AI_92`
// ALTER TABLE `pmd_azs_oil` ADD `AI_95P` FLOAT NOT NULL DEFAULT '0' AFTER `AI_95`

// ALTER TABLE `pmd_azs_group` ADD `LINK` TEXT NULL DEFAULT NULL AFTER `LOGO`

Просмотров 30 | Версия для печати »





Личный кабинет клиента каталога
Новости каталога
Мой блокнот (0)





Продукция и услуги

ООО «Мировая Металлургия»
Лист сталь 65Г 0,5мм, холоднокатаный лист ст.65Г от 0.5мм до 3мм х/к
Низкая цена на лист холоднокатаный из пружинной марки стали 65Г в компании ООО «Мировая ...

Студия Ногтевого Стиля Натальи Жугиной
Камуфляжный "Rich Cover Fleshly Gel" ТМ "ENI" 50 мг
Конструирующий камуфлирующий бежевый гель – густой вязкости.  Неподвижен, идеален для ...
1600


Ближайшие праздники

Через:
13 дней 01.10 - День пожилых людей
16 дней 04.10 - День Военно-космических сил
17 дней 05.10 - День учителя



Популярные категории

   Культура   (6904 Просмотров)

   Землеустройство   (6843 Просмотров)

   Финансы   (5616 Просмотров)

   Детские учреждения   (5593 Просмотров)

   Производство   (4719 Просмотров)




 
Оренбург © 2009 - 2019
Перепечатка информации возможна только при наличии согласия администратора и активной ссылки на источник
Мобильная версия | Вход для клиентов | Регистрация | Реклама на сайте | Наши партнеры | О проекте | Тарифные планы | Контакты Яндекс.Метрика