function casedetail() { $caseid = v('num'); $data['casecontent'] = get_case_by_id($caseid); $data['categorys'] = get_all_category(); $data['catename'] = get_catname_by_cat($data['casecontent']['category']); $data['title'] = $data['top_title'] = $data['casecontent']['title']; render($data); }
<?php require_once "../includes/sessions.php"; require_once "../includes/functions.php"; require_once "../includes/validation-functions.php"; require_once "../includes/db-connection.php"; include '../includes/layouts/header.php'; ?> <?php $page = "new-essay-question.php"; $cat = get_all_category(); ?> <body> <div id="wrapper"> <!-- Sidebar --> <nav class="navbar navbar-inverse navbar-fixed-top" role="navigation"> <!-- Brand and toggle get grouped for better mobile display --> <?php include '../includes/layouts/admin-head.php'; ?> <!-- Collect the nav links, forms, and other content for toggling --> <div class="collapse navbar-collapse navbar-ex1-collapse"> <?php include '../includes/layouts/admin-side-nav.php'; ?> <?php
require dirname(__FILE__) . '/includes/init.php'; require dirname(__FILE__) . '/includes/lib_order.php'; if ((DEBUG_MODE & 2) != 2) { $smarty->caching = true; } $tpl = 'stores.dwt'; $cache_id = sprintf('%X', crc32($cat_id . '-' . $display . '-' . $sort . '-' . $order . '-' . $page . '-' . $size . '-' . $_SESSION['user_rank'] . '-' . $_CFG['lang'] . '-' . $brand . '-' . $price_max . '-' . $price_min . '-' . $filter_attr_str . '-' . $filter)); $filter['id'] = empty($_REQUEST['id']) ? 0 : intval($_REQUEST['id']); $filter['keywords'] = isset($_REQUEST['keywords']) ? trim(addslashes(htmlspecialchars($_REQUEST['keywords']))) : ''; $filter['sort_by'] = empty($_REQUEST['sort_by']) ? 'sort_order' : trim($_REQUEST['sort_by']); $filter['sort_order'] = empty($_REQUEST['sort_order']) ? 'ASC' : trim($_REQUEST['sort_order']); $filter['page'] = empty($_REQUEST['page']) || intval($_REQUEST['page']) <= 0 ? 1 : intval($_REQUEST['page']); $cache_id = sprintf('%X', crc32(date('ymd' . '-' . $filter))); if (!$smarty->is_cached($tpl, $cache_id)) { //店铺分类 $cats = get_all_category(); //店铺列表 $shop_list = get_all_supplier(); //推荐分类中的店铺 //$tuijian = get_tuijian_shop($cats['tuijian']); /* 模板赋值 */ assign_template(); $position = assign_ur_here(); $smarty->assign('page_title', $position['title']); // 页面标题 $smarty->assign('ur_here', $position['ur_here'] . '> ' . $topic['title']); // 当前位置 $smarty->assign('helps', get_shop_help()); // 网店帮助 $smarty->assign('all', $cats['all']); //$smarty->assign('tuijian', $tuijian);
<?php include "get.php"; include "update.php"; /* variable */ // Category $all_category = get_all_category(); // Size Group $all_size_group = get_all_size_group(); // Color $all_color_group = get_all_color_group(); /* function database */ if ($_POST["btn-product-detail"] == 'Save Changes' || $_POST["btn-product-detail"] == 'Save Changes & Exit') { insert_product(); } else { $data = get_product_details(); }