User tests: Successful: Unsuccessful:
Existing approach still have a problem, it is always forcing the parameters defined in $defaultUrlParams
, and make it impossible to remove.
I suggest a different approach, take the allowed parameters from the router, and filtering them before adding. Also this now happen in the pagination constructor, which allows for developers to unset unneeded params.
Code review. Test with your component.
Or, add following code, somewhere here
joomla-cms/templates/cassiopeia/index.php
Line 202 in 67cd90e
<?php
$pg = new \Joomla\CMS\Pagination\Pagination(100, 0, 20);
$pg->setAdditionalUrlParam('tmpl', null);
echo $pg->getPaginationLinks();
?>
Then open any page with ?tmpl=index
in URL, and check pagination links.
Somehow works.
Pagination links contain ?tmpl=index
.
Works but better.
Pagination links without ?tmpl=index
.
Please select:
Status | New | ⇒ | Pending |
Category | ⇒ | Libraries |
Labels |
Added:
bug
PR-4.4-dev
|
I updated the PR, it now takes only allowed parameters.
Testing now, after getting more information, it seems to be working fine for me. I will do more tests to confirm this PR. Thank you.
I have tested this item ✅ successfully on 097ef2e
I have tested this item 🔴 unsuccessfully on 097ef2e
When going to page 2, link to first page in pagination contains parameter start=0. It should contain no start parameter (null).
Generally this aproach is much better than the hardcoded one introduced in 4.4.7, however doesn't solve the whole issue. start=0 would lead to duplicate pages issues, search engines wouldn't be happy :(
Title |
|
I have tested this item ✅ successfully on 399ab15
In combination with patch #44069 this works as expected.
Status | Pending | ⇒ | Ready to Commit |
RTC
Labels |
Added:
RTC
|
Status | Ready to Commit | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2024-09-23 07:23:34 |
Closed_By | ⇒ | MacJoom |
Thank you!
This PR re-introduces the issue that was fixed in the security release.