1
votes

I made an application in Joomla 3. Had a custom component in front end, which showing the details of a selected category.

Which the URL with out enable search engine friendly and URL rewrite as follows

wwww.sitename.com/index.php?option=com_arts&view=category&id=12

So I enabled the URL rewrite, SEO URL and URL suffix

http://www.sitename.com/component/arts/12.html?view=category

But I am trying to get a URL like this

http://www.sitename.com/caterory/12

I generated the link to this page using

<?php echo JRoute::_('index.php?Itemid=115&id='.$cat->id); ?>

Can anyone please help

Thanks in advance

2

2 Answers

2
votes

To make the SEF router do what you want it to do, you have write your own router. You cannot, however, get rid of the component part of the URL.

Do do that, you do not need your own router, but a menu entry for each category. That menu does not have to be displayed, if you don't want to show it. The alias of that menu entry is then used for the SEF URL.