Enable 'tags similar' module. Nothing rendered. Admittedly this is not a module I am familiar with but regardless of settings I presume I should at least get a module title.
Something
Nothing even if title enabled. countModules
comes back as true so in the frontend I get a blank space where I expect to have a module
Labels |
Added:
?
|
It is a matter of taste, some want the module with title, some want no module at all.
Which for me looks like an error in html if a columns is empty and also if the content is wmpty.
Maybe we can display a text in the module "No similar tags found"?
@chmst - that was the previous behaviour.
While testing this issue I realised that this current behaviour is completely correct. Similar tags is different to other modules.
Using the Sample data as an example. We have a menu item for a blog category. The similar tags will never have any matches if displayed on the category page. But the only way to have a similar tags module on the article page is to assign the module to the blog category menu item.
Ideally then I guess the if ($this->countModules())
statement should return false if the tags similar module is empty.
The entire point of this code change was to prevent the blank space. (which it does on the sample data). If it doesnt then thats a bug. Could you please share the template code so we can try and debug
I believe the above example is pretty much using the sample data ('testing' data on cassiopeia). I disabled all other modules in the sidebar-left
position with the exception of the tags similar module (I positioned it there if not already done so).
ok - taking a look. It does sound like a bug
Confirming its a bug as far as I am concerned - i have an idea
Ideally then I guess the if ($this->countModules()) statement should return false if the tags similar module is empty.
So it turns out that the code exists.
If you change
if ($this->countModules('position))
to
if ($this->countModules('position', true))
This code was added to Joomla 4 by @Fedik #19416
I guess we all forgot it existed and learned something new today
Nice.. that one is certainly news to me and resolves this issue.
I'll create the PR
the PR for what?
Closing as we have a PR
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2021-02-02 20:44:19 |
Closed_By | ⇒ | chmst |
#24879 means that you get nothing at all if there are no similar tags
Obviously you will only get similar tags if you are on a single article
With the sample data installed -