i using jquery pass data following url in cakephp 1.2 app:
$("#test").load("http://domain.com/controller/action/productid:2001642/questionid:2501322/value:c%2b%2b/questiontype:3", function({ $("#test").fadeout(3000); });
in controller when
debug($this->params['named']);
it returns
array ( [productid] => 2001642 [questionid] => 2501322 [value] => c [questiontype] => 3 )
the url part of $this displays
[url] => array ( [url] => deu/productanswers/updateoredit/productid:2001642/questionid:2501322/value:c /questiontype:3 )
so somewhere along line c++ or c%2b%2b getting squished.
does have solution or workaround please?
cheers, taff
although interested in cakephp solution, resorted using $_server['request_uri']
definitely not sexy solution
$tmp1 = explode('value:',$_server['request_uri']); $tmp2 = explode('/',$tmp1[1]); $prod=$this->params['named']['productid']; $ques=$this->params['named']['questionid']; $value=urldecode($tmp2[0]);
hope helps in future...
Comments
Post a Comment