Codeigniter check HTTP method– It is very simple we can detect the HTTP request method whether it is POST Or GET. You can use input library to check the HTTP method.
Codeigniter check HTTP method Example
Using input library you can check the get or post method simply as below-
| Example:
if($this->input->post()){ // do something } if($this->input->get()){ // do something } |
Thus you can detect the post method or get method HTTP requst.