Forums

How to change Attachment fields (Title, Caption, etc.) (2 posts)

  1. klint01
    Member
    Posted 5 months ago #

    I have a front-end posting form that users fill-in to submit a post on my site. With it I use 'media_handle_upload' to upload and create the image attachment that is then associated with the post.

    I am looking for a way to update the attachment Title, Caption and Description fields. By default it sets Title = file name and Caption & Description are left blank.

    I have been unsuccessful in finding the correct function that can be used to change the attachment fields in my code.

    TIA

  2. klint01
    Member
    Posted 5 months ago #

    I figured it out. Finally identified that the fields are stored in the wp_posts table along with the post.

Reply

You must log in to post.

About this Topic

Tags