?
avatar ozipom
ozipom
23 Nov 2017

Steps to reproduce the issue

Update Joomla to 3.8.2

Click on the title of an article displayed in a featured menu item.

Expected result

New router with no id url

Actual result

url ads /?view=article&id=

System information (as much as possible)

PHP 7
Joomla 3.8.2

Additional comments

If Joomla can't solve basic URL issue maybe we should use other cms ?

avatar ozipom ozipom - open - 23 Nov 2017
avatar joomla-cms-bot joomla-cms-bot - change - 23 Nov 2017
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 23 Nov 2017
avatar franz-wohlkoenig franz-wohlkoenig - change - 23 Nov 2017
Category Router / SEF
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 23 Nov 2017

Have you asked for help on the forums - Migrating and Upgrading to Joomla! 3.x?

avatar franz-wohlkoenig franz-wohlkoenig - change - 23 Nov 2017
Status New Information Required
avatar ozipom
ozipom - comment - 23 Nov 2017

@franz-wohlkoenig they have simple solution on forums - just use other cms Joomla can't solve basic URL issue now

Thats why it is now on github issues

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 23 Nov 2017

I asked cause after Release of 3.8 there where similar Reports depending most Time on Update from 3.6 (if i remember correct) and earlier and as you wrote "Update Joomla to 3.8.2". @wojsmol was one of the Guys here and in forums to help.

avatar ozipom
ozipom - comment - 23 Nov 2017

@franz-wohlkoenig if you have working solution to Joomla 3.8 new routing system disaster please post it here.
We need Joomla 3.8.3 asap to fix this joomla disaster or as forums suggests just use other cms

avatar wojsmol
wojsmol - comment - 23 Nov 2017

@franz-wohlkoenig Issue reported by @ozipom is IMHO not related to failed update.
@ozipom Did you enabled new routing system for com_contect?

avatar ozipom
ozipom - comment - 24 Nov 2017

@wojsmol I enabled new routing system for com_contect

The Home menu items give url /?view=article&id= instead of url with no id when the home is a featured view.

I see @infograf768 gets similar issue with Joomla 4 #16691

Maybe we also need @Hackwar to step in, couse now when the home is a featured view Joomla 3.8 url is disaster.

avatar Hackwar
Hackwar - comment - 24 Nov 2017

So you misconfigured your website and you are now asking for help. I am oh-so-glad to help you use our oh-so-broken CMS.

A featured view can not create URLs to articles, since it just creates a sort of copy/"shortcut" from the actual location to the featured view, ("shortcut" in terms that it does not force you to copy the article into another article again, but not in the terms that it changes/shortens the URL) If Joomla can not create a right SEF URL with modern routing, it does not SEF the URL. So either change your featured view to a category view or create a menu item for the category of your articles.

This is not a bug, but expected behavior.

avatar Bakual
Bakual - comment - 24 Nov 2017

This is not a bug, but expected behavior.

Maybe we need to document that better then or even add a postinstall notice for when there is only a feature menuitem?
Because actually it is quite common for smaller sites to have only a featured menuiitem and it used to work just fine with the legacy router.

avatar brianteeman
brianteeman - comment - 24 Nov 2017

Documentation is not the solution and if it worked before then I stronlgy believe it should work now

avatar infograf768
infograf768 - comment - 24 Nov 2017

@Hackwar
please see #16691 for 4.0
I have issues there on a mutilingual site which are not appearing in staging (home pages when they are featured menu items, articles links.)
Evidently, my test site contains for each language a hidden menu item to All Categories.

Documentation is not the solution and if it worked before then I stronlgy believe it should work now

Indeed: one MUST have at least a All categories menu item for each language if one wants to get rid of the article link issue in a Featured menu item.

avatar Hackwar
Hackwar - comment - 24 Nov 2017

@Bakual
It worked "fine" in that it displayed some URLs that people wanted. But it is and was one of the main reasons why Joomla accepted next to anything as a valid URL and created duplicate URLs for so many things. So, yes, it worked "fine" in that it was broken and Joomla has a bad reputation because of that.

@brianteeman
We had this discussion numerous times before. Modern routing is a new feature and thus WILL not and SHOULD not be feature identical to the legacy routing. Modern routing fixes duplicate URLs being generated for the same content, falsely returning a 200 result instead of a proper 404, predictable behavior for URLs, removal of IDs, etc. and thus this is a necessary and right step. For all those that don't want to switch over yet, they can simply stay with legacy routing until Joomla 4.0.

@infograf768
You don't need to have an all categories menu item for each language. You need a proper category and menu structure, that is all.

avatar infograf768
infograf768 - comment - 24 Nov 2017

That does not make sense, except if you totally take off from Joomla the Featured Articles Menu item.

avatar infograf768
infograf768 - comment - 24 Nov 2017

And if the blog menu item takes into account the Featured status of articles....

avatar Bakual
Bakual - comment - 24 Nov 2017

it worked "fine" in that it was broken

It worked fine in that it created a nice looking URL. If it was broken or not doesn't matter in that regard.

avatar mseidl73
mseidl73 - comment - 24 Nov 2017

The new router is not good!

See my problems at #16030.
Tags, mod_article_latest ... nothing works correct, also on legacy mode!

On my webpage Chem-Page.de:
In the »Inhalt« module there are submenu items (eg in experiments) that are linked to a tag. For example, click on »Experimente - Analytik« and select an experiment from the list, the correct article will appear, but the wrong page header will appear and the article information will not be displayed!
Or choose an article in the Bottom modules (News, Neue Experimente & Synthesen, Neue Tutorials, Neu in der Datenbank): the correct article will appear, but the wrong page header will appear and the article information will not be displayed!

The only Quick fix is to use components/com_content from Joomla! 3.6.5!


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/18818.

avatar Hackwar
Hackwar - comment - 24 Nov 2017

The Joomla core components organise their content in a tree structure. (https://en.wikipedia.org/wiki/Tree_structure) A category can contain other categories and other articles, but no category can have more than one category as a parent and an article can not have more than one category assigned to it. That is also why we do not have multi-category in Joomla by default. Menu items form a similar tree and based on the type of menu item, the tree of menu items is extended with the sub-tree of the component that the menu item points to. So if you have a category menu item and that points to category1, which in return contains category1.1 and category1.2, then the menu item turns from a leaf into an internal node with category1.1 and category1.2 as new leafs (or internal nodes, depending on possible articles in those categories, etc.)

A tree is a well defined structure and does not allow cross-shortcuts. What you guys are expecting with the featured view are exactly such shortcuts, which result in the tree being broken and undefined and in the end this results in the huge number of issues that we had in the routing.

The featured article is nothing else than a favorites display of your articles. Think of a photo app. You organise your images into different albums and then mark some of them as your favorites. The favorites view of the app will then display those images in an overview, but the moment that you click on that image, you get into the album of the original image. It does not create a completely new album.

avatar Hackwar
Hackwar - comment - 24 Nov 2017

@mseidl73
There is no difference between the routing in Joomla 3.6 and 3.8, unless you enable modern routing.

avatar mseidl73
mseidl73 - comment - 24 Nov 2017

@Hackwar
But why does my webpage not correct working, when nothing has changed?
When i use the com_conten from 3.6.5, all is correct, with 3.7.x-3.8.x not.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/18818.

avatar Hackwar
Hackwar - comment - 24 Nov 2017

All that said, the discussions are running around in circles for the last 8 years. Either you base your system on a sound theoretical and logical basis (like the modern routing tries to do) or you create a rather random system, where everyone comes up with his own ideas how it should work and which has loads of flaws. Since I'm fed up with such discussions, I'm stepping out of this one right here.

avatar ozipom
ozipom - comment - 24 Nov 2017

@Hackwar after your teoretical new routing system has been introduced with Joomla! 3.8 it made real sites using featured menu disaster. So how can we fix this issue?

What is a proper category and menu structure for Joomla 3.8 now?

If disaster is Joomla 3,8 expected behavior it should be documented.

@Bakual where can we read documentation on how to use featured menu as home page and not expierence Joomla 3.8 disaster? If featured menu is not posible anymore what we should use then ?

avatar Bakual
Bakual - comment - 24 Nov 2017

@ozipom I think there is currently no documentation, that's why I said maybe we should add one.
From what I heard, you can use the featured menuitem, but you need another menuitem (hidden or not) for the parent category of your articles. Then it should work.

avatar csthomas
csthomas - comment - 24 Nov 2017

If we could break B/C on J3 for only Modern Routing, then we can stop adding Active Menu and Default Menu Item to every URL without own Itemid.

Instead of /index.php?view=article&id=...
we will get /component/content/article/article-alias&catid=1

I know that /component/content/article/article-alias&catid=1
is not so beautiful but we can change it to /component/content/article/cat1-alias/cat2-alias/article-alias by next PR.

If we can not change it then IMHO this issue won't be fixed.

avatar mseidl73
mseidl73 - comment - 24 Nov 2017

I have tested 4.0.0 alpha 2. No Problems with router.

avatar mbabker
mbabker - comment - 24 Nov 2017

OK, featured and archived articles have the same problem. And any view that is not directly related to content hierarchy will too.

Featured is a state. Archived is a publication state. How can an archived view be the parent of a category or article when archived is not part of the content hierarchy? Same goes for featured.

With the old routing system, the router would very weirdly use those non-hierarchical based views as parents and generate URLs. Sometimes questionable, but they would pass most user expectations of having a SEF URL versus the query string fragments they see now.

The new routing system just doesn't do that. Rightfully so. There are ways to change things so you get semi-pretty URLs, but if you are relying on content being routed to with SEF URLs from a featured or archived view then you really need to have the menu tree set up appropriately. com_content is the only component with this issue in core IIRC, but the same logic applies to any component which builds views that are not based on the content hierarchy but based on content state.

avatar Bakual
Bakual - comment - 24 Nov 2017

com_content is the only component with this issue in core IIRC,

Com_contact -> featured as well. Just to a much lesser degree since it is likely only rarely used.

avatar ozipom
ozipom - comment - 25 Nov 2017

Who understands this new Joomla 3.8 sef url and can write documentation? @Hackwar claims Joomla 3.8 website is misconfigured. If it so we need documentation, on how to setup main manu right way. Can @Hackwar step in and share with community the right configuration or there are others one who understands this new home is a featured view Joomla 3.8 url disaster.

avatar Bakual
Bakual - comment - 25 Nov 2017

Basically what you need is a menuitem (starting point for the router) for the parent category. So either a "categories" or "category" type menuitem. That menuitem just has to exist. It doesn't have to be visible, you can also have it hidden.
The home menuitem doesn't really matter. It can be anything. What is important is only that there is a starting point for the router to build the URLs. And unlike the legacy router, the new one can't use the featured menuitem as a starting point (for reasons Michael explained).

avatar ozipom
ozipom - comment - 25 Nov 2017

@Bakual what we need to choose as a starting point for the router to build the URLs using Joomla 3.8 that the protostar template displayed results of website would be simillar to protostar template Featured Articles then it was main menu? If Articles » List All Categories we make home page it shows only these categories, but how to display articles and pictures as it was with featured articles ?

avatar csthomas
csthomas - comment - 25 Nov 2017

You can have your Featured view for home page.

You have to add menu item (list or blog) for each root category or use menu item for all categories view.

Example menu

  1. Menu item with Featured view (for special featured articles - home page)
  2. Featured menu only for featured articles from category "X" (alias featured-x)
    2.1. Category menu item for category "X" (x-news)

Then for article from category "X" you should get link /featured-x/x-news/article

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 26 Dec 2017

If this Issue get no Response, it will be closed at 26th January 2018.

avatar csthomas
csthomas - comment - 9 Jan 2018

The issue will be fixed by #19280

avatar franz-wohlkoenig franz-wohlkoenig - change - 14 Jan 2018
Status Information Required Closed
Closed_Date 0000-00-00 00:00:00 2018-01-14 11:02:54
Closed_By franz-wohlkoenig
avatar joomla-cms-bot joomla-cms-bot - change - 14 Jan 2018
Closed_Date 2018-01-14 11:02:54 2018-01-14 11:02:55
Closed_By franz-wohlkoenig joomla-cms-bot
avatar joomla-cms-bot joomla-cms-bot - close - 14 Jan 2018
avatar joomla-cms-bot
joomla-cms-bot - comment - 14 Jan 2018
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 14 Jan 2018

closed as having Pull Request #19280.

avatar geqo
geqo - comment - 10 Jul 2018

Newly installed joomla have same problem, links to articles look like
/?view=article&id=10:vremennyj-10&catid=2
Link was created by default way Route::_(ContentHelperRoute::getArticleRoute($item->id, $item->catid))

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 10 Jul 2018

@geqo can you please open a new Issue? Comments on closed Issues didn't get much Notice.

avatar ggppdk
ggppdk - comment - 10 Jul 2018

@geqo

there is no bug, it is like this by design

you will get such URLs if an appropriate menu item is not found for current view
e.g. you unpublished or changed access/language or did not create the needed menu items

If you want prettier URLs, check that you have menu items linking to at least your top level categories,
and that are of a language and of an access level that can be selected during creation of page for current viewing user

e.g. for guest users
check that you have menu items linking to at least your top level categories
of public access with language all

avatar arashtad
arashtad - comment - 23 Oct 2018

The reason why you see a query string like "/?view=article&id=" instead of a SEF URL is that you probably have no menu item assigned to the category yet. I explain this with an example.

Problem

  1. You got a category with alias "blog-posts" including blog articles.
  2. You want to display its articles with a clean URL like https://site.com/blog/article-alias
  3. You turn the modern routing system on and see it generates an ugly query strings like "/?view=article&id=" instead of the expected URL above.
  4. You get confused and look for another way, even maybe hacking the router.php file of com_content, like what you probably had been doing on the previous versions. But you see it goes even worst.

If I'm right so far, then follow the instruction below and let me know the result.

Solution

  1. Go to menus > [YOUR_DESIRED_MENU] > Create new menu item.
  2. Give the item an alias that you'd like to see before the article alias on the URL. E.g. if you want the URL look like "https://site.com/my-blog/article-alias", then give the item "my-blog" as alias.
  3. Now, turn the modern routing system on, give a yes to the "Remove ID from URL" option and that's it!

Note:
If you wouldn't like to display the menu item at the front end, use the old trick and create a menu called hidden menu without any module at the front end and put the blog menu item there.

avatar Milo-W
Milo-W - comment - 7 Apr 2021

Hello,
OK, but what about other links, not menu items?

It's incredible how the Joomla community finds out strange solutions for simple things so that in the end, you have to try this, that, etc. and people tell you that it's YOUR fault, "wrong config", etc. Joomla will never be this "great CMS that everyone wants to use" due to such cases... all the time basic stuff that e.g. WP has out of the box, we need to have first of all awaited for years, then developed in a strange way the devs "think" it should be done and then, when you have a problem with a given solution, you are just scolded.
This solution here is not a solution. Just built a website, turned on those "modern" URLs and I got some IDIOTIC stuff for blog "read more" links like
/path/?view=article&id=3:the-title-of-the-news-item&catid=9
How can you say something works allright if, after normal usage and config, it produces such crap???

EDIT: Read the "solution".
OMG so you HAVE to have a menu on the site - again! We had such a solution for a different problem like 10 years ago! And yet we still use such crap solutions! AGAIN you NEED to have a menu item... OMG... it brings back those memories of hidden menu items because Joomla can't build URLs... so many years and this crap is still in place...

avatar Bakual
Bakual - comment - 8 Apr 2021

If you don't like the menu-driven URLs of Joomla, then maybe just don't use Joomla - it may not be the best solution for you.
On the other hand, this system allows you do create the URLs exactly the way you want it.

avatar Milo-W
Milo-W - comment - 25 Aug 2021

Wow, an awesome piece of advice... a basic thing Joomla should have - it doesn't have it? Don't use it. Wow. And then you are wondering why Joomla is deteriorating...

Add a Comment

Login with GitHub to post a comment