News:

Dear forum visitors, if the support forum is not available, please try again a few minutes later. Thanks!

Main Menu
Support-Forum

"Select all files" no longer works - Layout "Compact Files layout with Checkboxes 3.9"

Started by LinaG, 04.05.2026 17:42:51

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

LinaG

Hello!
I had activated the "Compact Files layout with Checkboxes 3.9" plugin to allow downloading multiple files at the same time. In this version 4.1.3, the "Select all files" button appears but doesn't select any files. How do I get it working again?
Thanks
  •  

ColinM

Hi,
I reproduced your result so I tried 'ticking' each individual box (select-all-files01.png). After clicking on the Continue button it listed the set of files in a Summary View as expected (select-all-files02.png).  Next pressed the Download Button. This gave a 404 error 'Requested page cannot be found' (select-all-files03.png).
Joomla 6.1
jD 4.1.3 Stable

ColinM
Colin M
  •  

LinaG

Hi, thank you for testing!
In my case I am running Joomla 5.4.5 + jD 4.1.3. The checkbox "Select all files" was not working (neither select-all nor individual checkboxes were functional), but after applying the JavaScript workaround described below, both selecting files and downloading (including the ZIP package) work correctly — no 404 error.
So it seems there are actually two separate bugs:
1.    Checkbox bug (Joomla 5 + PHP 8.x) — onclick attributes on both the toggle and individual checkboxes are malformed in the generated HTML (value onclick= instead of two separate attributes), so the handlers never fire and boxchecked stays empty.
2.    404 on Download — which you reproduced on Joomla 6.1 but I cannot reproduce on Joomla 5.4.5.
Workaround for bug #1 (add to the "User After layout" field of the active checkbox Files layout):
html
<script>
document.addEventListener('DOMContentLoaded', function () {

    window.istChecked = function(isChecked, catid) {
        var boxchecked = document.querySelector('input[name="boxchecked"]');
        if (!boxchecked) return;
        if (isChecked) {
            boxchecked.value = 1;
        } else {
            var anyChecked = document.querySelectorAll(
                'input[name="cb_arr[]"]:checked'
            ).length > 0;
            boxchecked.value = anyChecked ? 1 : 0;
        }
    };

    window.checkAlle = function() {
        var toggle = document.querySelector('input[name="toggle"]');
        if (!toggle) return;
        var isChecked = toggle.checked;
        document.querySelectorAll('input[name="cb_arr[]"]').forEach(function(cb) {
            cb.checked = isChecked;
        });
        var boxchecked = document.querySelector('input[name="boxchecked"]');
        if (boxchecked) boxchecked.value = isChecked ? 1 : 0;
    };

    document.querySelectorAll('input[name="toggle"]').forEach(function(t) {
        t.addEventListener('change', checkAlle);
    });

    document.querySelectorAll('input[name="cb_arr[]"]').forEach(function(cb) {
        cb.addEventListener('change', function() {
            istChecked(this.checked, 160);
        });
    });

});
</script>
  •  

ColinM

Lina
Clearly there is some missing code.
In my opinion the code you have defined should be included within jD itself, not in the Use After Layout section of the  "Compact Files Layout with Checkboxes v3.9".  There maybe other cases in other layouts so I will look at these.
Best wishes
ColinM
Colin M
  •  

ColinM

Lina
This is also a 'challenge' with layout "Standard Files Layout with Checkboxes" as expected.  So any correction code really does need to be in jD itself
ColinM
Colin M
  •  

LinaG

Thank you ColinM for investigating this further and confirming the root cause. I'm glad the workaround helped identify the issue. Looking forward to the fix in a future version!
Best regards,
Lina
  •  

ColinM

Have also tried with layout Standard Files Layout with Checkboxes v3.9
It has the same problem.
ColinM
Colin M
  •  


Arno

Hi Lina,
thank you for reporting this and for the helpful workaround.

We were able to reproduce the problem and found two issues in the legacy checkbox download flow. Both have now been fixed for the upcoming 4.1.4 version.

I will send you a PM with a 4.1.4 test package so you can check whether both the Select all function and the download link now work correctly in your setup.

Arno
Best Regards / Gruß
Arno
Please make a Donation for jDownloads and/or write a review on the Joomla! Extensions directory!
  •  

Arno

Hi Lina,
Unfortunately, the bug hasn't been fully fixed yet. Sorry about that. So you don't need to test the version I sent you. I'll send you a new one today.
Best Regards / Gruß
Arno
Please make a Donation for jDownloads and/or write a review on the Joomla! Extensions directory!
  •  


LinaG

Hi Arno,
I cannot see any attachment or download link for version 4.1.4 in the message.
Could you please send the package or the download link?
Thanks.
  •  

Arno

Hi Lina,
I sent you that version as an attachment to a private message. Not here in this thread.

But I've already released that version in the meantime, so you can install it in the usual way.  ;)
Best Regards / Gruß
Arno
Please make a Donation for jDownloads and/or write a review on the Joomla! Extensions directory!
  •  

LinaG

Hi Arno,
I've already tried the new version and I don't think it's working without using the code in Use After Layout. The "Select all files" button doesn't select any files.
  •  

Arno

Quote from: LinaG on 15.05.2026 18:48:55Hi Arno,
I've already tried the new version and I don't think it's working without using the code in Use After Layout. The "Select all files" button doesn't select any files.

Either you don't have the latest version installed, or you should clear your browser cache and try again.

You're also welcome to see it working successfully for yourself on
the demo installation
. See pics.
Best Regards / Gruß
Arno
Please make a Donation for jDownloads and/or write a review on the Joomla! Extensions directory!
  •