Ouzo\Uri::getParams PHP Method

getParams() public method

public getParams ( )
    public function getParams()
    {
        $path = $this->_pathProvider->getPath();
        $pathElements = $this->_parsePath($path, 3);
        return $this->_splitParamsKeyValueMap($pathElements);
    }

Usage Example

示例#1
0
 /**
  * @test
  */
 public function shouldParseUrlWhenSlashInGET()
 {
     //given
     $this->_path(Config::getPrefixSystem() . '/user/add/id/4?param1=path/to/file&param2=val2');
     //when
     $params = $this->uri->getParams();
     $paramsExpected = array('id' => 4, 'param1' => 'path/to/file', 'param2' => 'val2');
     //then
     $this->assertEquals($paramsExpected, $params);
 }
All Usage Examples Of Ouzo\Uri::getParams