Keyword

Cannot Hide Category ID from URL

  • Mr_Anonymous
  • Mr_Anonymous's Avatar Topic Author
  • Offline
  • Premium Member
More
9 years 3 months ago #135748 by Mr_Anonymous
Cannot Hide Category ID from URL was created by Mr_Anonymous
I am trying to add category id from url but its not working. I have installed K2 2.6.9 on Joomla 3.3.6 and did the following:

1) Enabled Advanced SEF
2) Added Prefix for Category URLs
3)' Use the category ID in the URL' setting set to 'No'

Now, when I go to front end, the category page still has url like this: example.com/content/34-category-name

Why isint it working? Is it supposed to remove the number '34' from the category URL?

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
9 years 3 months ago #135764 by Krikor Boghossian
Replied by Krikor Boghossian on topic Cannot Hide Category ID from URL
Hello and Happy New Year,

The /content/ part is it a blank menu item or the correct prefix?

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

  • Mr_Anonymous
  • Mr_Anonymous's Avatar Topic Author
  • Offline
  • Premium Member
More
9 years 3 months ago - 9 years 3 months ago #135784 by Mr_Anonymous
Replied by Mr_Anonymous on topic Cannot Hide Category ID from URL
Thank you Krikor. Happy new year to you too.

In the example I showed the /content/ is not a menu item. Just a prefix.

In my actual set-up, this is how I have it. I have the main category (lets call it parent-category) as a menu item. All sub-categories under this 'parent-category' doesnt have a menu item and I want these subcategories to use the /content/ prefix. So right now, the sub-category url looks like this:

example.com/parent-category/content/989-sub-category

In the above, the 'parent-category' is the menu item and the '989-sub-category' is the sub-category id and the name which is not a menu item and has the 'content' prefix. I want to drop the sub-category id from the url so it looks like this instead:

example.com/parent-category/content/sub-category

I thought the 'Use the category ID in the URL' setting does that. But even when its set to 'No', the sub-category id is still showing in the url. Is that how its supposed to be?
Last edit: 9 years 3 months ago by Mr_Anonymous.

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
9 years 3 months ago #135830 by Krikor Boghossian
Replied by Krikor Boghossian on topic Cannot Hide Category ID from URL
Hello,

Since this category is mapped into a menu item, then the advanced SEF will not work.

The point in these settings is to use them if you don't have your content mapped into menu items. It is more of an "either or" situation . You need to use of these methods (menu mapping or Advanced SEF)

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

  • Mr_Anonymous
  • Mr_Anonymous's Avatar Topic Author
  • Offline
  • Premium Member
More
9 years 3 months ago - 9 years 3 months ago #135836 by Mr_Anonymous
Replied by Mr_Anonymous on topic Cannot Hide Category ID from URL
ah.. that makes sense on why my sub-categories was showing the category id. Thank you Krikor for clarifying that.

I do have 1 last question on this Krikor if you dont mind. I am thinking of maybe creating menu items for all sub-categories too mainly due to module controlling and controlling other components access to it. But what I am concerned is, if my main menu starts to grow with 100s of menu items (since its a big site), would that affect the loading speed or performance significantly in the frontend for users? Just to be clear, although my menu has 100s of menu items, I will not be loading all of these menus in front end (that will be crazy lol..). The frontend main menu module will only be loading the parent categories (that is 5 categories - start level 0 and end level 0). All other sub-category menu items will not be shown in frontend and its only used for backend purposes. In this case, if all of the menu items are not loaded in frontend module, would that still affect the performance for users because the main menu has 100s of menu items to query? Can Joomla / K2 handle this? Does it makes sense?

Sorry, I understand its really more of a Joomla question rather than K2. I asked in Ioomla forum and no one has answered this for me. Can you kindly share me your views please?
Last edit: 9 years 3 months ago by Mr_Anonymous.

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
9 years 3 months ago - 9 years 3 months ago #135852 by Krikor Boghossian
Replied by Krikor Boghossian on topic Cannot Hide Category ID from URL
It does make sense.
By doing this you reduce the risk of having duplicate content. Together with a canonical link plugin (for K2) you have a really solid setup for your SEO.

In the past I've helped develop Joomla! site with hundreds of menu item which ran without an issue.
Now since you are worried about performance, make sure to do two things, Enable caching, choose the right VPS and you should have nothing to worry to about.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Last edit: 9 years 3 months ago by Krikor Boghossian.

Please Log in or Create an account to join the conversation.

  • Mr_Anonymous
  • Mr_Anonymous's Avatar Topic Author
  • Offline
  • Premium Member
More
9 years 3 months ago #135871 by Mr_Anonymous
Replied by Mr_Anonymous on topic Cannot Hide Category ID from URL
Thank you so much Krikore. That gives me a sign of relief. I was concerned on this and your reply put me to ease. I have structured my site and its should be ready to go live in couple of days. Very excited and nervous at the same time.

I really appreciate your support you had always given me. Thank you humbly!

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
9 years 3 months ago #135881 by Krikor Boghossian
Replied by Krikor Boghossian on topic Cannot Hide Category ID from URL
You are welcome :)

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

More
8 years 7 months ago - 8 years 7 months ago #146974 by Alexander Tamirov
Replied by Alexander Tamirov on topic Cannot Hide Category ID from URL
Hello, Krikor.

Since this category is mapped into a menu item, then the advanced SEF will not work.

The point in these settings is to use them if you don't have your content mapped into menu items. It is more of an "either or" situation . You need to use of these methods (menu mapping or Advanced SEF)

Could you explain: when parameter "Use the category ID in the URL" makes sense??
It doesn't work in any conditions for me. Of course, i tried not to use menu mapping for K2 category or K2 item. But category Id still present in URL ((.
All other settings works (Use the item ID in the URL, even Use the category title alias)
Joomla! v. 3.3.6, K2 v. 2.6.9
Last edit: 8 years 7 months ago by Alexander Tamirov.

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
8 years 7 months ago #147005 by Krikor Boghossian
Replied by Krikor Boghossian on topic Cannot Hide Category ID from URL
It has been fixed in the DEV version.
You can get it from:

The patch that fixes it is located here: getk2.org/assets/get/
github.com/joomlaworks/k2/commit/4371e2e8571e9c0d94ee23723da5084f6ecf9435

PS. You are highly advised to backup first.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum