I have the following problem/setup:
I develop a custom component in Joomla that has multiple views. The views should have links to each other. If I enable SEF in the global configuration, the links in the menu are something like
/<menu-alias> depending on the rewriting rules.
Assume the views to be called
b. The corresponding menu entries have aliases
menuB (just for simpler communication here). If I open the
menuA entry, a link to view
b will look like
/menuA?view=b. I would rather prefer to have a url like
I need this changed url because the menu entries will not be in the very same menu and the visibility of the menu's module will depend on the current menu entry. And this will break depending of the url to be either
I found this documentation on joomla docs that clearly indicates the way the routing works and that a modification (call it optimization) of the url needs to be performed before SEF rules are applied. However there are no
[Component]RouteHelper classes in the current joomla core as mentioned and I think the class
Joomla\CMS\Helper\RouteHelper is not what I am looking for (at least I do not get a good documentation on its usage).
Another stack exchange question gave me the impression that manual searching in the database might be an option.
How can I find the correct url of the "other" view programatically in a clean way?