Zend Framework

getParams() ignores Zend_Controller_Request::setParamSources()

Details

  • Type: Patch Patch
  • Status: Resolved Resolved
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.6.0RC1
  • Fix Version/s: 1.9.6
  • Component/s: Zend_Controller
  • Labels:
    None

Description

I tried to set param sources for _GET only. bug Zend_Controller_Front::getParams() still returns _POST variables

try following code

$_POST = array();
$_POST['test'] = 'ZF BUGGED!';
var_dump($this->_request->getParamSources());
$this->_request->setParamSources(array('_GET'));
var_dump($this->_request->getParamSources());
$params = $this->_request->getParams();
var_dump($params);

  1. Zend_Controller_Request_Http.patch
    04/Feb/09 10:26 AM
    0.7 kB
    Johannes Wenzel
  2. zf-3750.patch
    24/Jun/09 9:40 PM
    2 kB
    Mike Willbanks

Activity

Hide
Johannes Wenzel added a comment -

This Patch fixes the problem. Please apply it to the trunk. Thank you very much and keep on the good work!

Show
Johannes Wenzel added a comment - This Patch fixes the problem. Please apply it to the trunk. Thank you very much and keep on the good work!
Hide
Mike Willbanks added a comment -

Added patch. This patch is a slight update from the prior patch provided in terms of whitespace and a fix in the comment.
Also added a test case for this issue.

Show
Mike Willbanks added a comment - Added patch. This patch is a slight update from the prior patch provided in terms of whitespace and a fix in the comment. Also added a test case for this issue.
Hide
Matthew Weier O'Phinney added a comment -

Patch applied and committed to trunk and 1.9 release branch – thanks, Mike!

Show
Matthew Weier O'Phinney added a comment - Patch applied and committed to trunk and 1.9 release branch – thanks, Mike!

People

Vote (4)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved: