[eluser]Clooner[/eluser]
[quote author="tzi0" date="1283182265"][quote author="Jeroen Schaftenaar" date="1283180952"]You should call your function using call_user_func_array and pass func_get_args for arguments! Your code doesn't pass through any arguments and logically it always will be none![/quote]
Code:
function _remap($method)
{
if ($this->session->userdata("user_id"))
{
var_dump (func_get_args());
$this->$method();
} else
{
$this->index();
}
}
it says that i have one arg only - my method's name, but without id ([/quote]
Why not try and read the documentation of the func_get_args on php.net? It means there are no arguments passed to the _remap method!
Either make sure that happens or simply pass the uri segment array as argument.