Home  >  Article  >  php教程  >  xotpl框架

xotpl框架

WBOY
WBOYOriginal
2016-06-06 19:34:512409browse

?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";
?>
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";
?>
Statement:
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
Previous article:empty函数Next article:【伪】类自动加载