Probably, this sort of questions are asked before but those doesn't address my problem. Anyway, I'm using this routing settings in my applications/config/routes.php
file
$route['most-popular-movies-(:num)'] = 'movies/search/popular/$1';
where
- Controller = movies
- Function = search
- Segment1 = popular
- Segment2 = (Page #)
Now, I want to get the two segments in my controller but it seams routing overwrites the segments and I'm just getting one segment i.e: most-popular-movies-1
when using $this->uri->segment_array()
Any Standard Solution?
EDIT:
I can use this method to split the URI inside my controller
explode('-', $this->uri->segment(1));
but this doesn't look to be a standard.