Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Update XoopsFormRendererBootstrap5.php #1379

Merged
merged 1 commit into from
Oct 16, 2023
Merged

Update XoopsFormRendererBootstrap5.php #1379

merged 1 commit into from
Oct 16, 2023

Conversation

CHCCD
Copy link
Contributor

@CHCCD CHCCD commented Oct 9, 2023

Move 'MAX_FILE_SIZE' go forward

Move 'MAX_FILE_SIZE' go forward
@mambax7
Copy link
Collaborator

mambax7 commented Oct 11, 2023

Should it be also changed for XoopsFormRendererBootstrap4.php ?

Also, can you give a background for this change?

The order of hidden input elements is generally not significant in HTML forms, and Bootstrap 5 doesn't impose any additional constraints or behaviors that would make the order significant in this case.

Copy link
Contributor

@geekwright geekwright left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technically, CHCCD is correct.

See: https://www.php.net/manual/en/features.file-upload.post-method.php

The MAX_FILE_SIZE hidden field (measured in bytes) must precede the file input field, ...

Changes similar to this would be needed in the other XoosFormRenderer* classes

I am a bit surprised by this being an issue, but it is documented in PHP.

@mambax7 mambax7 merged commit bb33abb into XOOPS:master Oct 16, 2023
mambax7 added a commit to mambax7/XoopsCore25 that referenced this pull request Oct 16, 2023
@mambax7 mambax7 mentioned this pull request Oct 16, 2023
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants