I tried to access an id from a URL "myfolder/mycontroller/mymethode/123" which I call into an AJAXcall.
I cannot access them, in "mycontroller" under the "mymethode". I tried to output $_GET, $_POST, $this->input->get(), $this->input->post(), but all array are empty.
In the Controller/mycontroller I have this
public function mymethode($listid=false)
{
echo "listid: $listid";
print_r($_GET);
print_r($_POST);
print_r($this->input->get());
print_r($this->input->post());
}
The Ajax call is this and is ok with Status 200.
$.ajax({
url: http://mydomein.com/myfolder/mycontroller/mymethode/123,
type: "POST",
method: 'post',
data: form + "&" + additional_data + csrfName + "=" + csrfHash,
dataType: 'json',
cache: false,
success: function(res){...
If I tried to open the URL directly, I have the same problem.
What can the reason for it be?