html模板中的值如何返回到php程序中啊。

浏览:614 发布日期:2014/04/06 分类:求助交流
模板中的值如何返回到php程序中啊。
就是比如Indexaction.php中定义是这样的
$this->display("./Tpl/Index/index.html");

$log = R('Getdata/log',array('1',$who,'追溯查询','追溯查询',$id,'查询成功'));

而我在index.html中,
想这样写
<script type="text/javascript">
try{
if (/Android|webOS|iPhone|iPod|BlackBerry/i.test(navigator.userAgent)) {
//window.location.href="index1.asp";
<?php
$who='手机用户';
?>
}else{
<?php
$who='电脑用户';
?>
//window.location.href="index2.asp";
}
}catch(e){}
</script>

我想问,怎么样把$who从html中传到php中。
最佳答案
评论( 相关
后面还有条评论,点击查看>>