Ejemplo n.º 1
0
                    $strtheme = decbin($rows["fieldnowvalue"]);
                    $strthemelen = strlen($strtheme);
                    $chars = preg_split('//', $strtheme, -1, PREG_SPLIT_NO_EMPTY);
                    for ($k = 0; $k < $strthemelen; $k++) {
                        if ($chars[$k] == 1) {
                            $shopcoinstheme[] = $ThemeArray[$strthemelen - 1 - $k];
                        }
                    }
                    $tpl['catalognew']['show']['offers'][$key]['shopcoinstheme1'] = implode(", ", $shopcoinstheme);
                    continue;
                }
            }
        }
    }
    //показываем 10 последних отзывов о монете
    $tpl['catalognew']['reviews']['reviewusers'] = $catalognew_class->getReviews($catalog);
    //$tpl['show']['lhreg'] = "/shopcoins";
    $tpl['show']['lhreg'] = isset($_COOKIE['chref']) ? trim($_COOKIE['chref']) : (isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '/catalognew');
    if (substr($tpl['show']['lhreg'], -1) == '?') {
        $tpl['show']['lhreg'] = substr($tpl['show']['lhreg'], 0, strlen($tpl['show']['lhreg']) - 1);
    }
    $tpl['breadcrumbs'][] = array('text' => 'Каталог монет', 'href' => $cfg['site_dir'] . 'catalognew', 'base_href' => 'catalognew');
    $tpl['current_page'] = '';
    $tpl['breadcrumbs'][] = array('text' => contentHelper::$menu[$materialtype], 'href' => urlBuild::makePrettyUrl(array('materialtype' => $materialtype), $cfg['site_dir'] . 'catalognew'), 'base_href' => urlBuild::makePrettyUrl(array('materialtype' => $materialtype), $cfg['site_dir'] . 'catalognew'));
    if ($rows_main["gname"] && $rows_main["group"]) {
        $tpl['breadcrumbs'][] = array('text' => $rows_main["gname"], 'href' => urlBuild::makePrettyUrl(array('materialtype' => $materialtype, 'group' => array($rows_main['group'] => $rows_main['gname'])), $cfg['site_dir'] . 'catalognew'), 'base_href' => urlBuild::makePrettyUrl(array('materialtype' => $materialtype, 'group' => array($rows_main['group'] => $rows_main['gname'])), $cfg['site_dir'] . 'catalognew'));
    }
    $tpl['breadcrumbs'][] = array('text' => $rows_main["name"], 'href' => '', 'base_href' => '');
    $tpl['current_page'] = '';
} else {
    $tpl['catalognew']['error']['no_coins'] = true;