Will Chen
Will Chen

Reputation: 11

Shorten Joomla SEF URL Parent / Child / Sub Menu Items, Use only one alias without multiple parent alias

Is there anyway to only show the menu item alias in the URL without its parent alias? I know I can create a hidden menu with all items in the root level but this will make the breadcrumb unusable.

For example: www.mysite.com/grand-parent/parent/child

I like it to be just www.mysite.com/child

I have url rewrite/sef turned on using Joomla 2.5.

Thanks,

Will

Upvotes: 1

Views: 9042

Answers (7)

Sajeeb Ahamed
Sajeeb Ahamed

Reputation: 6390

I solve it by following these steps.

  • Create a hidden menu which is your child menu. (For creating the hidden menu go to the Link Type tab and select No for Display in Menu option).

  • Then create your parent menu with a type of anything under the System Links (except Menu Item Alias)

  • Create a menu (as a child of the parent menu you have created before) with the type of Menu Item Alias and select the hidden child menu you've created before as the Menu Item.

That's all. Now you can show your menu structure like-

|-Parent
|--Child

And when you click on the Child link the URL will look like mysite.com/child

Upvotes: 0

kilian agboton
kilian agboton

Reputation: 31

To perform what you want to do :

1- Install "Direct Alias" extension : http://extensions.joomla.org/extension/direct-alias

2- Go to "Menus" -> "All Menus Items" and select your menu item. After "Alias" field you will have two buttons "Relative" and "Inherited". Click on "Relative". It will transform to "Direct". Save and test. You have now a direct link for your child item in your menu.

Note : If you don't install Direct "Direct Alias" extension the two button will not display.

Upvotes: 1

Elliot
Elliot

Reputation: 111

I have just had a similar problem and this plugin worked perfectly to achieve what I needed. This saves me hours of work creating 301 redirects. I had to buy the pro version to get the control over individual menu items. This gives you the functionality Ben Shomer describes above eg Next to it there's a button "Inherited". Click it so it becomes "Not Inherited". The free version controls ALL menu item aliases. Great plugin, highly recommended.

Upvotes: 1

Wito
Wito

Reputation: 11

It work's with "Direct Alias" extension.

http://extensions.joomla.org/extension/direct-alias

After instaling it "Inherited" button apears next to "Alias".

Upvotes: 1

Ben Shomer
Ben Shomer

Reputation: 36

No need for any workarounds. It works straight on.

(Written for J 2.5 but J 3 should be the same)

  1. Choose the menu item which you wish to remove from the SEF URL (the parent menu which provides the url). Open it from the menu manager

  2. In the section on the left, titled "Details" there is a row with "Alias". Next to it there's a button "Inherited". Click it so it becomes "Not Inherited".

  3. Save & Close

  4. Voila! It disappears .

Upvotes: 1

JoomlaSriLanka
JoomlaSriLanka

Reputation: 21

There is a workaround.

Create a seperate menu and create menu item in that menu with required alias. Then on the menu you want the link in the first place, create a menu item of type menu Alias and select the seperate menu item as target. This way parent alias will no appear infront for any alias type menu items.

Upvotes: 1

Riccardo Zorn
Riccardo Zorn

Reputation: 5615

I'm not sure it's possible with core Joomla.

You can achieve this - and complete control over your SEF urls - with the sh404 extension.

Upvotes: 0

Related Questions