Solved

How to get Request object from View script? Zend Framework

Posted on 2009-04-05
2
5,818 Views
Last Modified: 2013-11-10
How can I get an instance of Request object from View script?

in Zend Framework

thanks
0
Comment
Question by:technoparkcorp
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 49

Accepted Solution

by:
Roonaan earned 500 total points
ID: 24072066
You should be able to get to your front controller and from there get to the request object:

$front = Zend_Controller_Front::getInstance();
$req = $front->getRequest();
0
 
LVL 14

Expert Comment

by:shobinsun
ID: 24072255
Hello,

You can use "getRequest()" method to do that.

For more about  that follow the links:

http://framework.zend.com/manual/en/zend.controller.action.html

http://devzone.zend.com/article/3350-Action-Helpers-in-Zend-Framework



Regards.
0

Featured Post

Secure Your WordPress Site: 5 Essential Approaches

WordPress is the web's most popular CMS, but its dominance also makes it a target for attackers. Our eBook will show you how to:

Prevent costly exploits of core and plugin vulnerabilities
Repel automated attacks
Lock down your dashboard, secure your code, and protect your users

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses how to implement server side field validation and display customized error messages to the client.
There are times when I have encountered the need to decompress a response from a PHP request. This is how it's done, but you must have control of the request and you can set the Accept-Encoding header.
The viewer will learn how to count occurrences of each item in an array.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

630 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question