April 13, 201214 yr wondering what the Command to execute on file after file uploaded successfully to make an image the feature image. Want to know this as i want to allow user to post posts to my wordpress site without going to the sites backend
April 13, 201214 yr You need to create an attachment from the image with the post as its parent, then: add_post_meta($post_id, '_thumbnail_id', $attachment_id, false); Edited April 13, 201214 yr by Renaissance-Design
April 17, 201214 yr Author i use the TDO mini forms and this has the upload option which adds a widget %%WIDGET:upload-files%% you have the option of Command to execute on file after file uploaded successfully (result will be added to log). Leave blank to do nothing: Add the above into the command but no joy.
Create an account or sign in to comment