I want to know if it’s possible to get all the images
that are in a post and his comments
, make them a thumbnail and put it before (or in a sidebar or something) the post title to show, just like Twitter
does. Of course it would be wonderful if you navigate to the comment where it was inserted if you click on a thumbnail
, but that’s something for later.
Is this possible, if so, how?
PS: I am not using a plugin, I just want to know if it can search for all the <img>
tags and make them thumbnails out of no where…
Getting all the images from the post, and adding them to the top of the post is relatively easy. You can do something like this: (Note, this is just a code example. I’m not 100% what you are looking for. Hopefully this is enough to get you started.)