How can I remove the view name from a Joomla 2.5 URL? I am using this code in my BuildRoute
method in router.php
file but I'm not able to remove view name:
if(isset($query['view'])){
$segments[] = $query['view'];
unset($query['view']);
}
and how can I remove component/mycomponent
from the URL. My URL is now like this:
http://example.com/index.php/component/mycomponent/myview/id-itemtitle.html