youtube get image

How to get images from posts (and videos)

Post thumbs on your home page or category archives look very snazzy. Here is a function you can put into your theme functions.php and call it in your index or archive templates, to show the thumbnail image extracted from the post. This is a quick and simple hack. The function will just get the url of the image, or in case you use Smart Youtube plugin the representing image of the video. That means you still need to resize it with CSS or create and save thumbnail.
2 Comments

About Vladimir

vladimir prelovac Hi! My name is Vladimir Prelovac. I am a computer engineer by profession and an adventurer by state of mind.

"I would love to change the world, I just don't have the source code yet."

Books by Vladimir

WordPress Plugin Devleopment Book WordPress Plugin Development: Beginner's Guide

Published by Packt Publishing, available online through Amazon. Click the image for more information.

Consulting Services

Professional WordPress Services, including custom developed plugins and themes

Expert on-site WordPress SEO consulting and an 'out-of-the-box thinking' approach to problems