smarty 如何把零给显示出来 用smarty 模板的时候0被控代替了 这个要怎么解决?? 在线等 先谢谢了 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 {foreach from=$sell_array key=k item=v}{$v['group_id']} //这里是0的时候不显示0{/foreach}[/code] 是不是foreach后面的k和v忘记加$符号了 我用的是Smarty 3.0.6版本的配置$smarty=new Smarty();$smarty->template_dir=path_root."//tpl/";$smarty->compile_dir=path_root."//smarty/templates_c/";$smarty->config_dir=path_root."//smarty/configs/";$smarty->cache_dir=path_root."//smarty/cache/";$smarty->cache_lifetime = 0; //设置缓存时间 $smarty->caching = false; //设置缓存方式 $smarty->left_delimiter = "{"; $smarty->right_delimiter = "}"; {foreach from=$sell_array key=k item=v}{$v['group_id']} //这里是0的时候不显示0 显示空白{/foreach}[/code] php exce执行mencoder进行转码问题。 基础问题,怎么回事 PHP 函数参数的疑问 windows2003+Apache+php+jsp+mysql配置问题 在php.ini配置smtp 有没有朋友有PHP5服务器可以让我合租啊 请教个问题,怎么用PHP连接ORACLE 请教:GreenAMP的问题,在线等!谢谢! 急寻 ,用PHP做的网站的 网址!!!!!! 有分 怎样获得今天是当年的第几天 php相关问题? url参数加密方法?
{$v['group_id']} //这里是0的时候不显示0
{/foreach}[/code]
配置
$smarty=new Smarty();
$smarty->template_dir=path_root."//tpl/";
$smarty->compile_dir=path_root."//smarty/templates_c/";
$smarty->config_dir=path_root."//smarty/configs/";
$smarty->cache_dir=path_root."//smarty/cache/";$smarty->cache_lifetime = 0; //设置缓存时间
$smarty->caching = false; //设置缓存方式 $smarty->left_delimiter = "{";
$smarty->right_delimiter = "}";
{$v['group_id']} //这里是0的时候不显示0 显示空白
{/foreach}
[/code]