示例#1
0
 */
if (!defined('IN_STORE')) {
    exit('Acess Denied');
}
$navid = empty($_REQUEST['navid']) ? null : intval($_REQUEST['navid']);
if (in_array($_REQUEST['navid'], array('index', 'notice', 'album', 'good', 'consume', 'groupbuy'))) {
    $navid = $_REQUEST['navid'];
}
$shopid = $_G['myshopid'];
if (intval($shopid) < 1) {
    cpmsg(lang('menu_home_waitmod'));
    exit;
}
require_once B_ROOT . './source/class/nav.class.php';
$_nav = new nav();
$nav_default = $_nav->get_shop_nav_default($_G['myshopid']);
if (!empty($_POST['valuesubmit'])) {
    $_BCACHE->deltype('detail', 'nav', $_G['myshopid']);
    $checkresults = array();
    $arr_data = array();
    $arr_data['name'] = $_POST['subject'];
    $arr_data['target'] = $_POST['nav_target'];
    $arr_data['available'] = $_POST['available'];
    empty($_POST['strongsubject']) ? $_POST['strongsubject'] = '' : ($_POST['strongsubject'] = 1);
    empty($_POST['underlinesubject']) ? $_POST['underlinesubject'] = '' : ($_POST['underlinesubject'] = 1);
    empty($_POST['emsubject']) ? $_POST['emsubject'] = '' : ($_POST['emsubject'] = 1);
    empty($_POST['fontcolorsubject']) ? $_POST['fontcolorsubject'] = '#      ' : ($_POST['fontcolorsubject'] = '#' . $_POST['fontcolorsubject']);
    $arr_data['highlight'] = sprintf("%7s%1s%1s%1s", substr($_POST['fontcolorsubject'], -7), $_POST['emsubject'], $_POST['strongsubject'], $_POST['underlinesubject']);
    if ($arr_data['highlight'] === '#        ') {
        $arr_data['highlight'] = '';
    }