Search code examples
joomlajoomla2.5categoriesjoomla-sef-urls

Joomla 2.5 + How to display the category in the url


I was hoping someone could help me. I've searched high and low for an answer for this one, and I haven't been able to find the exact answer (even within the forum).

How can I display the category name in the url in Joomla (v2.5). I have 2 categories in my site so far. For example, I have a category called Refrigeration. I created an article called test and put it under the Refrigeration category. But for some reason, it will only display in the URL as: www.something.com/test.html.
I would like it to display like this: www.something.com/refrigeration/test.html

I know you can create a hidden menu, using the category (such as "Refrigeration") as the parent, and placing the related articles underneath that category (ie - with "Refrigeration" as their parent). But this seems rather inefficient. I just really want to be able to separate my articles on the site into different categories, and have that category display in the url.

Or, is the only way to accomplish this to install an SEF extension?

Any help is greatly appreciated. Please let me know if I need to provide further information.


Solution

  • The default Joomla SEF functions solely on the menus structure. It's hard to believe, but once you accept that Joomla Menu's aren't for actually "building menus" and more for build url / site structure, life will become a bit easier.

    To do what you want, you can create the hidden menu for each category, and it should work without having to put each article as a menu item underneath in the hidden menu. However, it would be much easier to use a SEF component to handle it for you. There may be some lightweight plugins available, but I haven't seen one.

    SEF components can be found here: http://extensions.joomla.org/extensions/site-management/sef