[Explained] double category in URL

More
12 years 1 month ago #29507 by Hyper
hello, my problem persist...
SEF urls generated by Joomla 1.5.xx with Flexicontent 1.5.5, was this:

domain/category/subcategory/item/idxxx-alias

while upgrading to flexicontent 1.5.6 (RC8 - RC9), I obtain the following url:

domain/category/subcategory/idxxx-subcategory/idxxx-alias

Site works perfectly and flexi module can increase the functionality, but the real problem for me, are URLs. How can i Fix this?
ACESEF and similar, don't fix this 'issue', but hide only cid.

[Sorry for my english]

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

More
12 years 1 month ago #29516 by Hyper
Perhaps... I have found the problem.

in the old flexicontent (1.5.5), I could select the category from a single tree, but in new version (1.5.6), categories are divided into primary and secondary.
Whatever I select, system takes the same category and generate double URL.

Please... help me! :P

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

More
12 years 1 month ago #29520 by ggppdk
the primary and secondary always existed in backed item form , or you speak of another place ?


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

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

More
12 years 1 month ago #29523 by Hyper

ggppdk wrote: the primary and secondary always existed in backed item form , or you speak of another place ?


I'm sorry, I don't speak a perfect English, but ... I think there is a problem with the selection of categories (frontend and backand). I send you a PM with address and log-in for my website.

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

More
12 years 1 month ago #29527 by ggppdk
i cannot test in your site i have no backend access, but i have checked the code and i have a fix (or maybe call it improvement),

-- First note that: current category is important and must not be removed from the URL
-- but if it is the same as current selected category menu item the it is redundant and thus we could instead have this URL:

http://domain/parent1_menuitemalias/parent2_menuitemalias/cat_menuitemalias/item/id-item

instead of

http://domain/parent1_menuitemalias/parent2_menuitemalias/cat_menuitemalias/id-category/id-item

The above is possible by editing site/components/com_flexicontent/router.php
and changing :
Code:
case FLEXI_ITEMVIEW: if (isset($query['cid'])) {
to be
Code:
case FLEXI_ITEMVIEW: if ( isset($query['cid']) && ($query['cid'] != @$menu->query['cid'] && @$menu->query['view'] != 'category') ) { // cid EXISTs and doesnot much current menu item


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

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

More
12 years 1 month ago #29558 by Hyper
Thank you for reply.

I tried to change the code, but I have the CID at the end of URL.
I try to explain myself better ( :oops: ) ...

For example, when I create an article and choose a subcategory, this is automatically set me as both primary and secondary, and I think that's what generates the double category in URL. This applies only to nested categories.
If these are not nested, the URLs are perfect.

--

My scheme of categories:

cat1
|-sub1
|-sub2
|-sub3
cat2
|-sub4
|-sub5
|-sub6
cat3
cat4
...

if I create an article for sub1, I get a url like this:

domain/cat1/sub1/id-sub1/id-item
(double subcategory) because automatically set for primary and secondary, the same sub-category, in this case sub1.

if I create an article for cat4 and set for primary category cat3 and secondary cat4, I get a perfect URL, with output like this:

domain/cat3/cat4/id-item

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

Moderators: vistamediajoomlacornerggppdk
Time to create page: 0.457 seconds
Save
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline