(Frontend AJAX) get post data WITH image thumbnail?
The reason that your idea doesn’t work is, get_post returns a post object, not an array (if not set manually). This is a quote from WordPress code reference: When $output is OBJECT, a WP_Post instance is returned. Which is the default output type for get_post(). If you need to implement an array of data and … Read more