Calling another Controller's methods in CodeIgniterSubmitted by jessie on Mon, 04/16/2012 - 4:03pm |
Everyone says not to do it, but there are cases where I want to do it.
There is a way to do this.
Say you have a controller named products with a method named "_controller_method". Here's how to call it:
- require_once('products.php');
- $products = new products();
- $products->_controller_method($id);
- jessie's blog
- 2058 reads