{dede:field name='typename' runphp='yes'} global $test; $test = @me; @me = ''; {/dede:field} {dede:field name='id' runphp='yes'} global $test; function getnextone($one,$tow){ return $one."-".$tow; } $a = getnextone(@me,$test); @me=''; echo […]
在系统后台->模版->全局标签测试->将代码贴入,选择环境变量为任意一个栏目{dede:field name='typename' runphp='yes'}
global $test;
$test = @me;
@me = '';
{/dede:field}
{dede:field name='id' runphp='yes'}
global $test;
function getnextone($one,$tow){
return $one."-".$tow;
}
$a = getnextone(@me,$test);
@me='';
echo $a;
{/dede:field}