Home > php教程 > php手册 > xotpl框架

xotpl框架

WBOY
Release: 2016-06-06 19:34:51
Original
2530 people have browsed it

?php define(IN_ECS, true); require(dirname(dirname(__FILE__)) . /includes/init.php); $xoopsOption[template_main] = xotpl:mod_nv#nv_dapai.xotpl; $xoopsOption[xoops_pagetitle]=现在注册少一块-现金红包送给你哟 ; include XOOPS_ROOT_PATH./yheader

define('IN_ECS', true);
require(dirname(dirname(__FILE__)) . '/includes/init.php');

$xoopsOption['template_main'] = "xotpl:mod_nv#nv_dapai.xotpl";
$xoopsOption['xoops_pagetitle']="现在注册少一块-现金红包送给你哟" ;
include XOOPS_ROOT_PATH."/yheader.php";
$xoops->services['theme']->addStylesheet( 'css/red.css' );
$hnd = & xoops_getmodulehandler("goods","goods");

$crit = new CriteriaCompo(new Criteria('is_on_sale',1));
$crit->add(new Criteria('is_delete',0));

$crit->setSort('rand()');
$crit->setLimit(12);
$xoops_vars['goods'][0] = $hnd->getAll($crit,array('goods_name','goods_img','shop_price','market_price'),false);

$infos['goods'] = $xoops_vars['goods'];
$xoopsTpl->assign('infos', $infos); // 分类树
$xoopsTpl->assign('cart_show', insert_cartshow()); // 分类树
unset($xoops_vars);
include XOOPS_ROOT_PATH."/footer.php";
?>
<?php
define('IN_ECS', true);
require(dirname(dirname(__FILE__)) . '/includes/init.php');

$xoopsOption['template_main'] =  "xotpl:mod_nv#nv_dapai.xotpl";
$xoopsOption['xoops_pagetitle']="现在注册少一块-现金红包送给你哟" ;
include XOOPS_ROOT_PATH."/yheader.php";
$xoops->services['theme']->addStylesheet( 'css/red.css' );
$hnd = & xoops_getmodulehandler("goods","goods");

$crit = new CriteriaCompo(new Criteria('is_on_sale',1));
$crit->add(new Criteria('is_delete',0));

$crit->setSort('rand()');
$crit->setLimit(12);
$xoops_vars['goods'][0] = $hnd->getAll($crit,array('goods_name','goods_img','shop_price','market_price'),false);

$infos['goods'] = $xoops_vars['goods'];
$xoopsTpl->assign('infos',      $infos); // 分类树
$xoopsTpl->assign('cart_show',      insert_cartshow()); // 分类树
unset($xoops_vars);
include XOOPS_ROOT_PATH."/footer.php";
?>
Copy after login
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template