I need to give current page url and change action url. After that I want echo that in view file.
I want do these in view file, not controller!
Do you have any idea?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can get current page url as follows:
The view helper
$this->userAgent()returns an instance ofZend_Http_UserAgentthat can provide you with many useful info.If you want to get an action in your views you can get it as follows:
Not sure what you mean by ‘changing an action’. You want to change it when you echo it, or you want to redirect user. Anyway, hope this will help.