Welcome Guest, Not a member yet? Register   Sign In
HMVC and Cjax
#17

[eluser]salvomil[/eluser]
I got something to work, but it does not seem a good thing....

I modified the system file CodeIgniter.php as follow:


// Load the local application controller
// Note: The Router class automatically validates the controller path using the router->_validate_request().
// If this include fails it means that the default controller in the Routes.php file is not resolving to something valid.
if ( $RTR->fetch_class()=='AjaxController' ) {
$path = APPPATH.'controllers/'.$RTR->fetch_class().'.php';
}else{
$path = APPPATH.'controllers/'.$RTR->fetch_directory().$RTR->fetch_class().'.php';
}

if ( ! $path )
{
show_error('Unable to load your default controller. Please make sure the controller specified in your Routes.php file is valid.');
}
//include(APPPATH.'controllers/'.$RTR->fetch_directory().$RTR->fetch_class().'.php'); // Original
include( $path );

this because $RTR->fetch_directory() appends ../modules/module/controller .....

and it seem to go but I have not tested all the application....


Messages In This Thread
HMVC and Cjax - by El Forum - 01-29-2014, 04:11 AM
HMVC and Cjax - by El Forum - 01-31-2014, 05:44 AM
HMVC and Cjax - by El Forum - 02-02-2014, 06:30 AM
HMVC and Cjax - by El Forum - 02-07-2014, 06:53 AM
HMVC and Cjax - by El Forum - 02-10-2014, 08:46 AM
HMVC and Cjax - by El Forum - 02-10-2014, 09:23 AM
HMVC and Cjax - by El Forum - 02-10-2014, 09:58 AM
HMVC and Cjax - by El Forum - 02-10-2014, 11:54 AM
HMVC and Cjax - by El Forum - 02-10-2014, 12:45 PM
HMVC and Cjax - by El Forum - 06-08-2014, 01:05 PM
HMVC and Cjax - by El Forum - 06-12-2014, 09:34 AM
HMVC and Cjax - by El Forum - 06-12-2014, 04:38 PM
HMVC and Cjax - by El Forum - 06-13-2014, 05:39 AM
HMVC and Cjax - by El Forum - 06-13-2014, 01:10 PM
HMVC and Cjax - by El Forum - 06-14-2014, 02:52 PM
HMVC and Cjax - by El Forum - 10-29-2014, 12:25 AM
HMVC and Cjax - by El Forum - 10-29-2014, 02:18 AM



Theme © iAndrew 2016 - Forum software by © MyBB