Does Plugin System-SEF work for rel=canonical ?

Discuss Search Engine Optimization in relation to Joomla! 3.x. This forum will also have discussions on SEF/SEO Joomla! 3.x extensions.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
Locked
nfleming
Joomla! Apprentice
Joomla! Apprentice
Posts: 20
Joined: Fri Apr 09, 2010 1:34 am

Does Plugin System-SEF work for rel=canonical ?

Post by nfleming » Mon Mar 12, 2018 5:18 am

Hi,
I have a question regarding insertion of rel=canonical links. Can this be done in Joomla 3.8.5 by simply inserting the site URL into the System-SEF plugin and enabling it?

It seems that it is supposed to be included in Joomla3 core, but I have read in old posts (https://www.ostraining.com/blog/joomla/canonical/ ) that there is/was problems with the core and it shouldn't be used due to it not working correctly and causing more issues than it fixes.

Does anyone use it? Does it work, or is the best idea still to use "Styleware Content Canonical Plugin" ?

Thanks
Nicola

gws
Joomla! Champion
Joomla! Champion
Posts: 5950
Joined: Tue Aug 23, 2005 1:56 pm
Location: South coast, UK
Contact:

Re: Does Plugin System-SEF work for rel=canonical ?

Post by gws » Mon Mar 12, 2018 7:19 am

It has worked satisfactory for me by putting the url in.

VITSPL
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Thu Mar 22, 2018 3:04 pm

Re: Does Plugin System-SEF work for rel=canonical ?

Post by VITSPL » Tue Mar 27, 2018 1:47 pm

You can now choose which one would be the nicest one to appear in the search results (obviouslky the first one). This happens by adding the following piece of code in your source code:

<link href="http://......com/blogl" rel="canonical" />

OR

You can unset the canonical tag in your template's index.php file using the following code -
$doc = JFactory::getDocument();
foreach ( $doc->_links as $k => $array ) {
if ( $array['relation'] == 'canonical' ) {
unset($doc->_links[$k]);
}
}


Locked

Return to “Search Engine Optimization (Joomla! SEO) in Joomla! 3.x”