我爱占星网 我爱占星网
首页
编程
java
php
前端
首页 编程 java php 前端

将操作中的变量传递给ZF中的另一个操作视图

I want to know that does zend allow this thing and if yes than how?

public xAction()
{
// code here
}

public yAction(){
 $this->_helper->viewRenderer('x');
// code here....
// $this->view->variable= $somedata;
}

**x.phtml**

<?php echo $this->variable; ?>

Zend allows the rendering of a different view script. You can do it like this: $this->_helper->viewRenderer('controller/action', null, true);
More info here (Example #11)

近期文章

  • CakePHP访问hasMany中的表
  • 从特定关键字或位置遍历php
  • PHP / MySQL - 列出了谁招募的人
  • php保存带有特定文件名的图像,不会互相覆盖
  • 修剪图像中的空白,然后使用“填充”调整图像大小
  • 使用javascript从ajax响应中获取特定变量
  • Apache ERR_EMPTY_RESPONSE,日志中没有任何数据
  • 在codeigniter中设置会话加载
  • PHP preg_replace - 替换特殊字符之间的字符
  • 定期获取带有特定主题标签的推文?
  • TCPDF - 页面底部的空白区域
  • 1and1 mod_rewrite不使用子域
  • 错误:wordpress小部件上的“无法打开流”
  • 用户注册时,可能会将2个表连接在一起
  • PHP表单不插入数据
  • PHP页面使用location:from url参数重定向
  • PHP搜索和数据库结果
  • PHP NumberFormatter打印ISO 3货币代码
  • 有jQuery函数使用来自外部php文件的数据和mySQL查询
  • keepalived部署,只有本机能telnet通端口,其它设备只能ping通,是不是我哪里搞错了????、

Copyright ©2022 我爱占星 All Rights Reserved.

浙ICP备2022030071号-1

部分图文来自网络,如有侵犯您的版权,请告诉我们删除

友情链接:代码精华