2 Unrelated links highlighted in Auto Nav

Permalink
I have the following links on my Auto Nav,

1. Home
2. About
3. Products
4. Custom
5. News
6. Customer Service
7. Contact

The problem is after I click on "Customer Service", both "Custom" and "Customer Service" links are highlighted in the Auto Nav when I'm at "Customer Service" page.

I don't have the problem when I'm at the "Custom" page after clicking on "Custom" in Auto Nav.

Both pages aren't related at all.

Bascially, the problem only occurs when "Customer Service" page is selected.

I can't find much info on this error in the forum.

Any help is much appreciated! Thanks!

 
12345j replied on at Permalink Reply
12345j
whats your website?
Mnkras replied on at Permalink Reply
Mnkras
please try upgrading to 5.4.1.1, this is a known problem with 5.4.1, not sure if it was fixed with 5.4.1.1
mtbcms replied on at Permalink Reply
I'm already on 5.4.1.1. Any other possible solution I could try? Thanks!
mtbcms replied on at Permalink Reply 1 Attachment
[quote]whats your website? [/quote]

I've attached a screen cap for your reference.
Mnkras replied on at Permalink Reply
Mnkras
try this as a temporary work around,

download concrete5.4.0.5 navigate to /concrete/blocks,

upload the the autonav folder to /blocks on your site (not /concrete/blocks)
mtbcms replied on at Permalink Reply
I uploaded the folder but the problem still persist. Is there another workaround that I can try?

Thank you for your help!
Fernandos replied on at Permalink Reply
Fernandos
Are you sure that both pages lead to different urls? You can try to hover the link and look at the url in the status bar of your browser to compare if both urls are the same.

It may have happend that you copied or moved a page and that both pages now have a second alternative url that is the same..

http://i.imgur.com/kUc5q.png
mtbcms replied on at Permalink Reply
The urls for both links are different.
Mnkras replied on at Permalink Reply
Mnkras
clear your cache after you uploaded it
mtbcms replied on at Permalink Reply
Did that but it didn't resolve the issue.
pixmonkey replied on at Permalink Reply
pixmonkey
I ran into this issue today and I got it to work correctly by changing the canonical links to be more different from each other. Just thought I would let you know.
yoschi replied on at Permalink Reply
yoschi
I ran into the same issue, although you probably moved on, I'll post here what I did to get it working.

The problem lies in the following line in the template:
if ($ni->isActive($c) || strpos($c->getCollectionPath(), $_c->getCollectionPath()) === 0)

the strpos command gives a positive result even when only a part of a string is the same.

Change it to either this:
if ($ni->isActive($c) || ($c->getCollectionPath() === $_c->getCollectionPath())) {

or to this for ignoring the string comparison:
if ($ni->isActive($c)) {


I went with the first solution as I'm not sure if removing the string comparison would break navigation in a different situation later in the development.

edit:
It seems I went too fast with my answer, once you implement sub-navigation, the string comparison trick stops working...

Unfortunately I can't spend more time with this issue, so I'll have to make the canonical links more different from each other. If somebody manages to make similarly named links work, I would gladly appreciate the help though!