#22776 closed defect (bug) (fixed)
Ensure compat data is saved
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 3.5 | Priority: | normal |
Severity: | normal | Version: | 3.5 |
Component: | Media | Keywords: | has-patch |
Focuses: | 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)
#2
@
11 years ago
Original support thread that prompted part 1: http://wordpress.org/support/topic/doesnt-save-custom-field-selectbox-data-in-media-frame?replies=2
#4
in reply to:
↑ 3
@
11 years ago
Replying to nacin:
I don't know if we should do anything about this.
I meant for part 1.
+1 for part 2.
#5
@
11 years ago
- Owner set to nacin
- Resolution set to fixed
- Status changed from new to closed
In 23098:
#6
follow-up:
↓ 7
@
11 years ago
Replying to nacin:
I don't know if we should do anything about this.
I meant for part 1. Part 2 is in.
#8
@
11 years 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?