{"action":"created","issue":{"url":"https://api.github.com/repos/bcit-ci/CodeIgniter/issues/4397","labels_url":"https://api.github.com/repos/bcit-ci/CodeIgniter/issues/4397/labels{/name}","comments_url":"https://api.github.com/repos/bcit-ci/CodeIgniter/issues/4397/comments","events_url":"https://api.github.com/repos/bcit-ci/CodeIgniter/issues/4397/events","html_url":"https://github.com/bcit-ci/CodeIgniter/issues/4397","id":128519893,"number":4397,"title":"$this->input->post() Broken Returned Data","user":{"login":"mertdogan","id":1324617,"avatar_url":"https://avatars.githubusercontent.com/u/1324617?v=3","gravatar_id":"","url":"https://api.github.com/users/mertdogan","html_url":"https://github.com/mertdogan","followers_url":"https://api.github.com/users/mertdogan/followers","following_url":"https://api.github.com/users/mertdogan/following{/other_user}","gists_url":"https://api.github.com/users/mertdogan/gists{/gist_id}","starred_url":"https://api.github.com/users/mertdogan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mertdogan/subscriptions","organizations_url":"https://api.github.com/users/mertdogan/orgs","repos_url":"https://api.github.com/users/mertdogan/repos","events_url":"https://api.github.com/users/mertdogan/events{/privacy}","received_events_url":"https://api.github.com/users/mertdogan/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-01-25T11:48:05Z","updated_at":"2016-01-25T12:04:46Z","closed_at":"2016-01-25T12:02:22Z","body":"I'm using codeigniter 3.0.4 . I've experienced a problem and created a test structure for describe it here like below:\r\n\r\n```\r\nfunction dene1(){\r\n $url = site_url('Giris/dene2');\r\n $myvars = '_search=true&nd=1453717819822&rows=42&page=1&sidx=&sord=asc&filters=%7B%22groupOp%22%3A%22AND%22%2C%22rules%22%3A%5B%7B%22field%22%3A%22HTH2%22%2C%22op%22%3A%22eq%22%2C%22data%22%3A%22%3E7.5%2B%3C10%22%7D%2C%7B%22field%22%3A%22ST1Y%22%2C%22op%22%3A%22cn%22%2C%22data%22%3A%22100%22%7D%2C%7B%22field%22%3A%22ST2Y%22%2C%22op%22%3A%22cn%22%2C%22data%22%3A%22%3E55%2B%3C100%22%7D%5D%7D';\r\n echo '<h3>MYVAR ORIGINAL:</h3><code>'.$myvars.'</code><hr/>';\r\n echo '<h3>MYVAR URLDECODED:</h3><code>'.urldecode($myvars).'</code><hr/>';\r\n\r\n $ch = curl_init( $url );\r\n curl_setopt( $ch, CURLOPT_POST, 1);\r\n curl_setopt( $ch, CURLOPT_POSTFIELDS, $myvars);\r\n curl_setopt( $ch, CURLOPT_FOLLOWLOCATION, 1);\r\n curl_setopt( $ch, CURLOPT_HEADER, 0);\r\n curl_setopt( $ch, CURLOPT_RETURNTRANSFER, 1);\r\n\r\n $response = curl_exec( $ch );\r\n echo '<h3>MYVAR $this->input->post() RESPONCE:</h3><code>'.$response.'</code>';\r\n}\r\n\r\nfunction dene2(){\r\n print_r($this->input->post());\r\n}\r\n```\r\n\r\nThis functions are in a controller.\r\n\r\nWhen i visit site http://localhost:81/index.php/giris/dene1.html site; returned values like below:\r\n\r\n```\r\nMYVAR ORIGINAL:\r\n\r\n_search=true&nd=1453717819822&rows=42&page=1&sidx=&sord=asc&filters=%7B%22groupOp%22%3A%22AND%22%2C%22rules%22%3A%5B%7B%22field%22%3A%22HTH2%22%2C%22op%22%3A%22eq%22%2C%22data%22%3A%22%3E7.5%2B%3C10%22%7D%2C%7B%22field%22%3A%22ST1Y%22%2C%22op%22%3A%22cn%22%2C%22data%22%3A%22100%22%7D%2C%7B%22field%22%3A%22ST2Y%22%2C%22op%22%3A%22cn%22%2C%22data%22%3A%22%3E55%2B%3C100%22%7D%5D%7D\r\nMYVAR URLDECODED:\r\n\r\n_search=true&nd=1453717819822&rows=42&page=1&sidx=&sord=asc&filters={\"groupOp\":\"AND\",\"rules\":[{\"field\":\"HTH2\",\"op\":\"eq\",\"data\":\">7.5+<10\"},{\"field\":\"ST1Y\",\"op\":\"cn\",\"data\":\"100\"},{\"field\":\"ST2Y\",\"op\":\"cn\",\"data\":\">55+<100\"}]}\r\nMYVAR $this->input->post() RESPONCE:\r\n\r\nArray ( [_search] => true [nd] => 1453717819822 [rows] => 42 [page] => 1 [sidx] => [sord] => asc [filters] => {\"groupOp\":\"AND\",\"rules\":[{\"field\":\"HTH2\",\"op\":\"eq\",\"data\":\">7.5+<10>55+<100\"}]} )\r\n```\r\n\r\n\r\nI want to describe these structure. I have defined myvars string for post data to another controller function. I shown urldecoded style of myvars variable for simple understanding. And shown output of $this->input->post() .\r\n\r\nAs you can see; post() function is brakes HTH2 field and removes ST2Y field. (These are coming from jqgrid).\r\n\r\nWhen i use \r\n```\r\n$input=file_get_contents('php://input');\r\n$_GET = array();\r\nparse_str($input, $_GET);\r\n```\r\n\r\nstructure for gater input data, everything works well but $this->input->post() brakes data."},"comment":{"url":"https://api.github.com/repos/bcit-ci/CodeIgniter/issues/comments/174486289","html_url":"https://github.com/bcit-ci/CodeIgniter/issues/4397#issuecomment-174486289","issue_url":"https://api.github.com/repos/bcit-ci/CodeIgniter/issues/4397","id":174486289,"user":{"login":"mertdogan","id":1324617,"avatar_url":"https://avatars.githubusercontent.com/u/1324617?v=3","gravatar_id":"","url":"https://api.github.com/users/mertdogan","html_url":"https://github.com/mertdogan","followers_url":"https://api.github.com/users/mertdogan/followers","following_url":"https://api.github.com/users/mertdogan/following{/other_user}","gists_url":"https://api.github.com/users/mertdogan/gists{/gist_id}","starred_url":"https://api.github.com/users/mertdogan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mertdogan/subscriptions","organizations_url":"https://api.github.com/users/mertdogan/orgs","repos_url":"https://api.github.com/users/mertdogan/repos","events_url":"https://api.github.com/users/mertdogan/events{/privacy}","received_events_url":"https://api.github.com/users/mertdogan/received_events","type":"User","site_admin":false},"created_at":"2016-01-25T12:04:46Z","updated_at":"2016-01-25T12:04:46Z","body":"Thank you. I found problem and when i write something about it; i see your description.\r\n\r\n$this->input->post(null,false);\r\n\r\nreturns well."}}