Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

G5.5.4 - routing differences between J3.10.3 and J4.0.4 #2938

Open
marktaylor46 opened this issue Nov 11, 2021 · 4 comments
Open

G5.5.4 - routing differences between J3.10.3 and J4.0.4 #2938

marktaylor46 opened this issue Nov 11, 2021 · 4 comments
Labels

Comments

@marktaylor46
Copy link

marktaylor46 commented Nov 11, 2021

I tested this on a clean rocketlauncher installation of G5.4.37 and Helium

  1. add two tags "testtag1" and "testtag2"
  2. Filter on the blog articles and assign one tag or the other to each of the articles.
  3. edit "blog" menu item options and set tag to "show"
  4. Go to front end and click on "blog" and you get the list of blog articles each showing a tag
  5. Click on "testtag1" against one of the articles and you follow a link of the form "/index.php/component/tags/tag/testtag1"
  6. The list of articles for that tag correctly renders in the "default" outline
    2021-11-11_11-45-20
  7. Update to G5.5.4 and Helium for G5.5.4
  8. Look at blog on frontend again and Click on "testtag1" against one of the articles and you follow a link of the form "/index.php/component/tags/tag/testtag1"
  9. The list of articles for that tag correctly renders in the "default" outline
  10. Update to J4.0.4
  11. Look at blog on frontend again and Click on "testtag1" against one of the articles and you follow a link of the form "/index.php/component/tags/tag/testtag1"
  12. The list of articles for that tag does not show because this time the "home" outline is being used (which does not have a "page content" particle and therefore there is nowhere to render the list of articles). Also note that an error is showing in the browser console too
    2021-11-11_11-57-26
  13. If you then add a "page content" particle to the "home" outline layout then the list does render on the frontend and the error in the console is no longer present
@mahagr
Copy link
Member

mahagr commented Nov 15, 2021

It looks like Joomla 4 sets the menu item to home before onAfterRoute event where Joomla 3 didn't do that. This confuses the layout assign logic in Gantry and causes the wrong style to be used.

@mahagr
Copy link
Member

mahagr commented Nov 15, 2021

It looks like in Joomla 4 SiteRouter::parseRawRoute() always sets Itemid where Joomla 3 didn't do that. This basically means that everything which doesn't have a route (or menu item) will be using the home menu item instead of no menu item.

@mahagr
Copy link
Member

mahagr commented Nov 15, 2021

This behavior can be replicated with Cassiopeia, assign home menu item to it and set default to another template (such as Gantry). Joomla 3 used the other template, Joomla 4 uses the template style assigned to home menu item.

@morphinestyle
Copy link

Opened yesterday.
joomla/joomla-cms#37262

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants