Reputation: 14746
Is there anything in the wordpress APIs which will show me a list of images used in a post? Or do I need to look through the content of the post to find this?
Upvotes: 0
Views: 170
Reputation: 14746
Well, once again i ask a question before thoroughly looking for an answer. A quick google search turned up the following snippet of code:
$arrImages =& get_children('post_type=attachment&post_mime_type=image&post_parent=' . $iPostID );
I found this at http://wphackr.com/.
Upvotes: 1