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

xotpl框架

WBOY
WBOYOriginal
2016-06-06 19:34:512545Durchsuche

?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";
?>
Stellungnahme:
Der Inhalt dieses Artikels wird freiwillig von Internetnutzern beigesteuert und das Urheberrecht liegt beim ursprünglichen Autor. Diese Website übernimmt keine entsprechende rechtliche Verantwortung. Wenn Sie Inhalte finden, bei denen der Verdacht eines Plagiats oder einer Rechtsverletzung besteht, wenden Sie sich bitte an admin@php.cn
Vorheriger Artikel:empty函数Nächster Artikel:【伪】类自动加载