Completely inappropriate canonical tags

BodgeIT

Member
Hi just had a look at my Google Search console and found 3/4 of my pages, even ones presented through sitemap are excluded from the index.

When I looked at the source code I could see why.

The canonical is completely mashed up.

so for a url like this:
//domain.name/opportunities/account-handling/details/3/761-junior-account-manager

my canonical is:
href="/component/fabrik/details/3/761-junior-account-manager"

on a list page like this:
//domain.name/opportunities/account-handling

my canonical is
href="/component/fabrik/"

This has destroyed the ranking for this site. Is this Fabrik?
How can I change it?

Opportunities and account-handling both have menu items in the appropriate hierarchy.

Is there some configuration that I'm missing or something silly I've done or could this be related to the new router in Joomla?
 
Last edited:
I know nothing about ranking or search engines or SEO, so appreciate any input.

What would you expect the canonical link to look like for those two examples?

What we currently do is run the base link ...

index.php?option=com_fabrik&view=form&formid=X&rowid=Y

... (or view=details) or ..

index.php?option=com_fabrik&view=list&listid=X

... through JRoute::_(), to get whatever URL your current SEF settings dictates. Which should produce a relative link.

-- hugh
 
Hi Hugh, that technically sounds like it should produce the correct canonical but..
menu.jpg
If you see my menu, it should be following that structure so technically should look exactly the same as the good SEF urls above, not the component based fabrik ones.
 
Ah, but iirc, we can't do that ... that's kind of the whole point of canonical. Your menu items are just that - specific menu items. So the only link that has that link is that menu item. If you have two menu items to the same list, they would have different J! SEF aliases. So we deliberately don't include the Itemid in the call to JRoute::_() for a list/form, so we get the canonical component route, not the menu item specific one.

-- hugh
 
If you search the forums for 'canonical', you will find a couple of lengthy discussions on the topic, and how we arrived at doing it the way we do.

-- hugh
 
Hi Hugh, that sux!
I appreciate there are many ways to skin a cat but I expect the system to follow my lead, the menu is the only way I have to control the sef structure so for Fabrik to completely ignore it doesn't make any sense.

Not going to try and convince you to change it but could you help me remove your canonical?

I'd rather have no canonical than the one being presented.

As I said above the result of your approach is for Google to exclude all the good 'crafted menu controlled' urls from its index and stick with the canonicals you supply which are just ineffective. Over time it has excluded 700 good sef urls with the bad urls that are provided through the canonical tag.
 
Message edited:
"If you have two menu items to the same list, they would have different J! SEF aliases."
For this case, I would use one menu item and use a Joomla menu alias to point to it.

In the past this would keep the sef url the same(it would add a date to the alias config but translate through jroute) however some buffoon has decided that's not how it should work anymore and now aliases have their own sef alias...unbelievable.

Ideally, there should be prevention on creating duplicate menus with same parent to same list.

If different parent then the best option is to offer a choice as to which is canonical, i.e. a checkbox
 
Last edited:
The point about canonical URLs is that (as I understand it) they are supposed to tell Google what the definitive URL is when several different URLs point to the same content.

So if you have several menu items which point to the same URL, then you cannot have a canonical which is the menu item because then it would not be canonical.

And since Joomla / Fabrik cannot know what URLs might end up at the same content as this URL, it cannot predetermine what the nicest canonical URL might be - so it has to use a generic one. Choosing the right one is important (see what Yoast has to say about it for Wordpress) but Fabrik / Joomla probably can't know what you would prefer to be used.

It sounds to me like you need to find a Joomla Extension which will help you manage canonicals. Several I have come up with in a quick Google search are:
All that said:

a. I have a feeling that Joomla gives preferences to menu URLs over generic native URLs when choosing the canonical - perhaps fabrik should do the same;

b. According to Google's webmaster page, the canonical link should, as BodgeIT says, use an absolute URL:
Use absolute paths rather than relative paths with the rel="canonical" link element.

Use this structure: https://www.example.com/dresses/green/greendresss.html
Not this structure: /dresses/green/greendress.html

But whether these issues are Fabrik or Joomla, I an not expert enough to know.
 
"The point about canonical URLs is that (as I understand it) they are supposed to tell Google what the definitive URL is when several different URLs point to the same content."
This is true but what it also does is to help Google organise the information it indexes against a site. It prioritises the cananonical path relative to the content which is where some of the context for content is derived from and thus impacts ranking. And, perhaps more importantly, it excludes alternative urls to the same content if a canonical is present.

"So if you have several menu items which point to the same URL, then you cannot have a canonical which is the menu item because then it would not be canonical."
This is also true but this is a site build issue and is mitigated where possible by the safeguards built into Joomla, preventing duplicate aliases being created under the same parent.

So, the menu structure should still be used to the determine preferred cananical of the site builder. That is what is being indexed by Google afterall until the canonical tells it otherwise.
In the case of this site, not having the canonical at all is FAR better than having such a poor one, Google will revert to indexing content under structure of the menu, which I set.

The impact was so detrimiental, to the ranking of this particular site, I have hacked the Fabrik core to stop it.
I did also try one of the plugins (Slackware one) but it only works with Joomla pages.
 
Last edited:
"So if you have several menu items which point to the same URL, then you cannot have a canonical which is the menu item because then it would not be canonical."
This is also true but this is a site build issue and is mitigated where possible by the safeguards built into Joomla, preventing duplicate aliases being created under the same parent.
I am not sure that this is correct - the point is to prevent not only similar URLs e.g. "index.php/stuff" and "/stuff" and "/stuff?UTM-id=xyz" but also to only index the same content once if e.g. aliases point to it.

However this is a webmaster decision as to what the canonical fields should show, and so how the site is indexed. Webmaster can allow duplicate content to have different canonicals if they want the pages to be indexed separately - or have a common canonical if they want it to be indexed once.

It seems to me that that what you are describing is a combination of:
  • Fabrik issue
  • Possibly Joomla issue
  • The way canonicals work by default
I have not looked at Fabrik's canonicalisation code - I know not where it lies, and even if I did look at it I am not sure I would understand it, nor that I would know how to fix it - and any changes need to be tested VERY carefully to ensure that they are beneficial.

In particular, I think that Fabrik should search the menus - possibly only public menus - and pick the menu for the page with the shortest number of parts to it - using the current canonical only if it can't find a menu.

My web site in development is not indexed - so I would be happy to test out changes.

However, whilst this would be better, the default would still be to have a single canonical for each piece of content regardless of how many menu items point to it. If you want something different then I think you need another Joomla extension to allow you to allocate canonicals manually.
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top