wordpress-fieldmanager icon indicating copy to clipboard operation
wordpress-fieldmanager copied to clipboard

Custom attachment meta fields not displaying when new image is uploaded

Open andybaughman1 opened this issue 1 year ago • 2 comments

Description of the bug

WordPress version 6.2.2 Fieldmanager version 1.5.0

After uploading an image using a Fieldmanager media field, custom attachment meta fields do not initially display.

Steps To Reproduce

  1. Register custom attachment meta field(s) using apply_filters( 'attachment_fields_to_edit', array $form_fields, WP_Post $post )
  2. Register a new Fieldmanager media field using Fieldmanager_Media() on posts
  3. Upload new image to a post using this Fieldmanager media field
  4. Note the missing meta field(s) in step 1 after upload
  5. Click on a different media item in the Media Library, then click back on the newly uploaded image. The meta fields should now appear, but did not appear on the initial upload.

Additional Information

No response

andybaughman1 avatar Jun 05 '23 16:06 andybaughman1

Hey @andybaughman1, thanks for reporting this and for your steps to reproduce! This may be an issue in WordPress core, have you searched through Trac and/or GitHub?

mboynes avatar Jun 14 '23 20:06 mboynes

Hi @mboynes - I contacted WordPress VIP support about the issue and they asked that I submit a ticket with Fieldmanager. From what I found in my testing, this is only an issue with our media fields setup through Fieldmanager.

There was a related bug in Trac (https://core.trac.wordpress.org/ticket/58051), but was resolved in WP 6.2.

andybaughman1 avatar Jun 14 '23 20:06 andybaughman1