Article links in search results page are wrong.

General questions regarding the use of languages in Joomla! 3.x.

Moderators: infograf768, 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.
Post Reply
jstuardo
Joomla! Intern
Joomla! Intern
Posts: 70
Joined: Sun Jan 04, 2009 2:35 am

Article links in search results page are wrong.

Post by jstuardo » Tue Sep 15, 2020 6:57 pm

Hello,

I have Joomla 3.9.21 which has SEF URL's enabled.

All works perfectly, but search results page.

For example, this is the SEO link to an article (which is assigned a menu option whose root option is called "proyectos"):

Code: Select all

https://www.mydomain.com/proyectos/thearticle.html
So far, so good. However, when I do a search where that article is on the results, the link of the article is this:

Code: Select all

https://www.mydomain.com/component/content/article/thearticle.html?catid=13&Itemid=101
How can I get rid of "component/content/article" part and replace it by the menu option the article is assigned to? In this case, root menu option is called "proyectos".

If I disable SEF, I realized that this URL is for the menu option that is assigned to the article:

Code: Select all

https://www.mydomain.com/index.php?option=com_content&view=article&id=15&Itemid=160
And when searching, this is the actual URL for that article:

Code: Select all

https://www.mydomain.com/index.php?option=com_content&view=article&id=15:thearticle&catid=13&Itemid=101
Regards
Jaime
Last edited by toivo on Wed Sep 16, 2020 5:52 am, edited 1 time in total.
Reason: mod note: moved from 3.x SEO

jstuardo
Joomla! Intern
Joomla! Intern
Posts: 70
Joined: Sun Jan 04, 2009 2:35 am

Re: Article links in search results page are wrong.

Post by jstuardo » Wed Sep 16, 2020 2:16 pm

I found out that the problem is about the language. I have menu and articles with Spanish language. Only Home menu item is for All languages.

I changed the article menu item for All languages, and it worked. The right Itemid was being retrieved now.

Is this a bug or is there some workaround when working with site languages?

Regards
Jaime

User avatar
Per Yngve Berg
Joomla! Master
Joomla! Master
Posts: 27203
Joined: Mon Oct 27, 2008 9:27 pm
Location: Romerike, Norway

Re: Article links in search results page are wrong.

Post by Per Yngve Berg » Wed Sep 16, 2020 8:24 pm

The default menu item is not used on a Multi Language Site.

There is one default menu item for each language marked with a flag.

Have you folloved the tutorial for setting up a Multi Language Site?


Post Reply

Return to “Language - Joomla! 3.x”