[wp-trac] [WordPress Trac] #63561: The media upload button is not disabled when no image has been uploaded
WordPress Trac
noreply at wordpress.org
Sat Jun 28 10:28:34 UTC 2025
#63561: The media upload button is not disabled when no image has been uploaded
-------------------------------------+---------------------------------
Reporter: karinchristen | Owner: joedolson
Type: enhancement | Status: accepted
Priority: normal | Milestone: 6.9
Component: Media | Version:
Severity: normal | Resolution:
Keywords: has-patch needs-testing | Focuses: ui, administration
-------------------------------------+---------------------------------
Comment (by rollybueno):
== Test Report
=== Description
This report validates whether the indicated patch works as expected.
Patch tested: https://github.com/WordPress/wordpress-develop/pull/8966
=== Environment
- WordPress: 6.9-alpha-60093-src
- PHP: 8.2.28
- Server: nginx/1.27.5
- Database: mysqli (Server: 8.4.5 / Client: mysqlnd 8.2.28)
- Browser: Chrome 137.0.0.0
- OS: Linux
- Theme: Twenty Twenty-Five 1.2
- MU Plugins: None activated
- Plugins:
* Query Monitor 3.18.0
* Test Reports 1.2.0
* Transients Manager 2.0.7
=== Actual Results
1. ✅ Issue resolved with patch.
- Navigated to `Media → Add New → browser uploader`.
- Confirmed that the **Upload** button is now correctly disabled when
no file is selected.
- Also confirmed that if a file is selected and then upload is
canceled, the **Upload** button reverts back to the disabled state.
- Attempting to click the button without selecting a file no longer
triggers a `wp_die()` error because.. ..well you can't click it 👍 😅.
=== Additional Notes
- To test the patch, I fetched the pull request locally using:
`git fetch upstream pull/8966/head:pr-8966 && git checkout pr-8966`
- The UI behavior now aligns with expected usability and accessibility.
- No regressions observed in standard media uploading or drag-and-drop
functionality.
=== Supplemental Artifacts
**Before the patch**:
[[Image(https://i.imgur.com/cQ75Y5y.png)]]
**After the patch**: You can't click it by default
[[Image(https://i.imgur.com/WrIviOd.png)]]
**After the patch**: Conditional logic is working. You can only click if
you have selected a file. If you remove that, it reverts back to disabled.
[[Image(https://i.imgur.com/yx4ZoDv.png)]]
--
Ticket URL: <https://core.trac.wordpress.org/ticket/63561#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list