RTC bug PR-4.4-dev Pending

User tests: Successful: Unsuccessful:

avatar Fedik
Fedik
13 Sep 2024

Pull Request for Issue #44049 .

Summary of Changes

Fix removing of start=0 from pagination for the first page.

Testing Instructions

Visit Category Blog or another list view with pagination.
Visit second page, and check the link for first page.

Actual result BEFORE applying this Pull Request

Link contain start=0

Expected result AFTER applying this Pull Request

Link without start=0

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:
  • No documentation changes for docs.joomla.org needed
  • Pull Request link for manual.joomla.org:
  • No documentation changes for manual.joomla.org needed
avatar Fedik Fedik - open - 13 Sep 2024
avatar Fedik Fedik - change - 13 Sep 2024
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 13 Sep 2024
Category Libraries
avatar Mich-es
Mich-es - comment - 13 Sep 2024

It works!

avatar fgsw
fgsw - comment - 13 Sep 2024

@Mich-es can you open https://issues.joomla.org/tracker/joomla-cms/44069 and click button "Tested successfully" so the test is counted.

avatar ChristineWk ChristineWk - test_item - 13 Sep 2024 - Tested successfully
avatar ChristineWk
ChristineWk - comment - 13 Sep 2024

I have tested this item ✅ successfully on 44c8277


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44069.

avatar Mich-es Mich-es - test_item - 13 Sep 2024 - Tested successfully
avatar Mich-es
Mich-es - comment - 13 Sep 2024

I have tested this item ✅ successfully on 44c8277


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44069.

avatar richard67 richard67 - change - 13 Sep 2024
Status Pending Ready to Commit
Labels Added: bug PR-4.4-dev
avatar richard67
richard67 - comment - 13 Sep 2024

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44069.

avatar PhocaCz
PhocaCz - comment - 13 Sep 2024

On some places, I get '0'

image

So, for me, instead of:

if ($limitstart !== null && $limitstart !== '') {

this works:

if ($limitstart !== null && $limitstart !== '' && $limitstart !== '0') {
avatar Fedik
Fedik - comment - 13 Sep 2024

It is expected, when limitstart have a value, then it will be added to URL.
The router code is skipping only empty values.

avatar PhocaCz PhocaCz - test_item - 13 Sep 2024 - Tested successfully
avatar PhocaCz
PhocaCz - comment - 13 Sep 2024

I have tested this item ✅ successfully on 44c8277

Tested successfully with $hideEmptyLimitstart set to true. Thank you.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44069.

avatar Quy Quy - change - 13 Sep 2024
Labels Added: RTC
avatar Fedik Fedik - change - 13 Sep 2024
Title
Fix start=0 in the pagination
[4.4] Fix start=0 in the pagination
avatar Fedik Fedik - edited - 13 Sep 2024
avatar n3t n3t - test_item - 15 Sep 2024 - Tested successfully
avatar n3t
n3t - comment - 15 Sep 2024

I have tested this item ✅ successfully on 62b3a63


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44069.

avatar n3t
n3t - comment - 15 Sep 2024

Just an idea, wouldn't be better to have $hideEmptyLimitstart true as default? I guess probably there are more components using pagination with hidden start=0 than those requireing this syntax...


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44069.

avatar universewrld
universewrld - comment - 15 Sep 2024

To get rid of all the pagination duplicates, it is necessary for @joomla to have the rel="canonical" attribute for this type of page, indicating as a canonical page the version of the page without the ?start parameter.

@Fedik is it possible to add this to the current Issue?

as far as I know, there will be a solution for other types of duplicate pages in Joomla in Joomla 5.2, but there is no solution for the ?start parameter, which can be solved by adding a canonical link and then Joomla will be completely protected from all types of duplicate pages.

avatar Fedik
Fedik - comment - 15 Sep 2024

is it possible to add this to the current Issue?

Nope, it's not as simple as it might seem.

avatar richard67 richard67 - alter_testresult - 22 Sep 2024 - ChristineWk: Tested successfully
avatar richard67 richard67 - alter_testresult - 22 Sep 2024 - Mich-es: Tested successfully
avatar richard67 richard67 - alter_testresult - 22 Sep 2024 - PhocaCz: Tested successfully
avatar MacJoom MacJoom - change - 22 Sep 2024
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2024-09-22 20:56:47
Closed_By MacJoom
avatar MacJoom MacJoom - close - 22 Sep 2024
avatar MacJoom MacJoom - merge - 22 Sep 2024
avatar MacJoom
MacJoom - comment - 22 Sep 2024

Thank you!

Add a Comment

Login with GitHub to post a comment