User tests: Successful: Unsuccessful:
Pull Request resolves #48294 .
Fixes banners being displayed and opened when their primary category is unpublished or inaccessible to the current user.
The Banners module now filters banners by the published state and access level of their primary category. The direct banner click endpoint applies the same checks, so unavailable banners cannot redirect users or increment click counts.
Registered.Banners are displayed by the Banners module even when their primary category is unpublished or inaccessible to the current user.
The direct banner click URL also redirects to the destination and increments the click count in both cases.
Banners are not displayed when their primary category is unpublished or inaccessible to the current user.
The direct banner click URL returns a 404 response and does not increment the click count.
Please select:
Documentation link for guide.joomla.org:
No documentation changes for guide.joomla.org needed
Pull Request link for manual.joomla.org:
No documentation changes for manual.joomla.org needed
| Status | New | ⇒ | Pending |
| Category | ⇒ | Front End com_banners |
| Title |
|
||||||
This isnt going to be enough. You will need to modify the module as well so that it doesnt display at all when there are no banners to display.
To test this
create one banner in a category and set the category to be unpublished Publish the banner module in the sidebar-right with it set to select banners from the unpublished category
Expected behaviour
### Actual behaviour
![]()
But i think it's not related to this PR
Should we do that in the same PR?
it is related to this PR imho and should be in the same PR. Otherwise if we end up with only one of them you will have unexpected output on existing sites
| Labels |
Added:
PR-6.2-dev
|
||
| Category | Front End com_banners | ⇒ | Front End com_banners Modules |
it is related to this PR imho and should be in the same PR. Otherwise if we end up with only one of them you will have unexpected output on existing sites
done, can you check please?
it is related to this PR imho and should be in the same PR. Otherwise if we end up with only one of them you will have unexpected output on existing sites
done @brianteeman, can you check please?
I have tested this item ✅ successfully on 6ce5615
I have tested this item ✅ successfully on 6ce5615
@Reda-Muhamed Please read https://github.com/joomla/joomla-cms#which-branch-should-my-pull-request-target
If this is a bug fix and the bug exists in 5.4 and 6.1, too, then a PR should be made for the 5.4-dev branch.
In addition, please link to issue #46351 . I have closed your issue as duplicate report.
In future, please check other a text search on GitHub if there is already an issue before opening a new one.
Opening duplicate issues and creating PRs for a more or less randomly chosen target branch causes unnecessary work for maintainers.
Thanks in advance.
@Reda-Muhamed Please read https://github.com/joomla/joomla-cms#which-branch-should-my-pull-request-target
If this is a bug fix and the bug exists in 5.4 and 6.1, too, then a PR should be made for the 5.4-dev branch.
In addition, please link to issue #46351 . I have closed your issue as duplicate report.
In future, please check other a text search on GitHub if there is already an issue before opening a new one.
Opening duplicate issues and creating PRs for a more or less randomly chosen target branch causes unnecessary work for maintainers.
Thanks in advance.
I had initially planned to target 5.4-dev, but I found some differences between 5.4 and 6.2 that could cause conflicts, so I targeted 6.2 instead
Regarding the issue you mentioned, it covers the category access scenario, but not the unpublished-category scenario
Thank you for the clarification :)
This isnt going to be enough. You will need to modify the module as well so that it doesnt display at all when there are no banners to display.
To test this
create one banner in a category and set the category to be unpublished
Publish the banner module in the sidebar-right with it set to select banners from the unpublished category
Expected behaviour
Actual behaviour