I have a upload form where users can upload images and after that I'll create a post with the tile, description and the respective image! I can do this now using wp_insert_attachment! But now I would like to set automatically (using php code) the post thumbnail without having to do it on backend! The post thumbnail will be the image uploaded! Is there any way to do that?