#22776 closed defect (bug) (fixed)
Ensure compat data is saved
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Priority: | normal | Milestone: | 3.5 |
| Component: | Media | Version: | 3.5 |
| Severity: | normal | Keywords: | has-patch |
| Cc: |
Description
Two things for compat:
1) Some plugins were expecting compat to be rendered and saved when an image is uploaded (for things like default values of form elements). As a result, when an image is first uploaded, should we fire saveCompat?
2) The compat view should have the same save-on-removal features the attachment details have. Patch attached for that.
Attachments (1)
Change History (9)
koopersmith — 6 months ago
comment:1
koopersmith — 6 months ago
comment:2
koopersmith — 6 months ago
Original support thread that prompted part 1: http://wordpress.org/support/topic/doesnt-save-custom-field-selectbox-data-in-media-frame?replies=2
Replying to nacin:
I don't know if we should do anything about this.
I meant for part 1.
+1 for part 2.
- Owner set to nacin
- Resolution set to fixed
- Status changed from new to closed
In 23098:
Replying to nacin:
I don't know if we should do anything about this.
I meant for part 1. Part 2 is in.
comment:8
koopersmith — 6 months ago
Agreed. For part 1, it's bad any way you slice it — the bottom line is that we'd have fire an ajax request any time we encounter an attachment for either render and/or insert — and all this just to provide safety for not providing default values, which is a poor development practice in its own right (regardless of the version of WordPress that you run). We're going to let part 1 ride.

Test this by opening up the edit gallery view, selecting an image, and inputting some data into a compat field. While the field is still active, click on another attachment. Did the data save?