Upload Images from the Front End and Attach Them to Posts in WordPress
Use WordPress media_handle_upload() from the front end to upload one or more images and attach them to a post.
Use WordPress media_handle_upload() from the front end to upload one or more images and attach them to a post.