Clarification about media attachments uploaded via Voxel forms

  • Solved
  • Posted 2 months ago

Hi,

I’m working on a cleanup process for media files uploaded through Voxel post forms.

I’ve noticed that when a user uploads multiple images to a gallery field, all uploaded files are attached to the post via post_parent, even if only a few are actually selected and saved in the gallery.

Could you please confirm the following points?

Does Voxel always assign post_parent = post_ID when uploading media via the frontend form?

If a user removes an image from the gallery before saving, does Voxel detach it or leave it attached to the post?

Are there any additional meta keys (or JSON references) where Voxel stores the list of selected media IDs — apart from standard post meta / Elementor data?

Does Voxel perform any automatic cleanup of unused media files (those still attached to the post but not referenced in any field)?

I’m planning to build a nightly CRON job or MU-plugin that automatically removes orphaned media (older than 24 h, not used in any field).

Just want to make sure I’m not missing any internal logic or hidden dependency before I proceed.

Thanks a lot for your help!