Dress Your WordPress | Blog /

How to insert a Native WordPress Gallery into a Post with LightBox

You have uploaded the theme and activated it and now you get the following error: Fatal error: Call to undefined function register_nav_menus()

Facebook stuff How to Dress your WordPress 1 Comment

If you want to share all your favorite blog posts and other articles in your Google reader with your followers on Twitter and Facebook, here is a pretty easy way to do it.

Today I am going to show you how to add a YouTube Channel to a post or page using a short code. So open up your functions.php file and copy the follow in there. Make sure to include it between the php tags . function youtubechannel($atts){ extract(shortcode_atts(array( 'user_name' => '', 'show' => '', 'width' => '', ), $atts)); $feed = new SimplePie(); $feed->set_feed_url("http://gdata.youtube.com/feeds/api/users/".$user_name."/uploads"); $feed->enable_cache(false); $feed->set_timeout(5); $success = $feed->init(); $feed->handle_content_type(); $YT_PlayerPage = "http://www.youtube.com/user/".$user_name."#play/uploads/"; $YT_VideoNumber = 0; $ShowMax = $show-1; foreach ($feed->get_items() as $item) { if ($enclosure = $item->get_enclosure()) { $YT_VideoID = substr(strstr($item->get_permalink(), 'v='), 2, 11);?>

So WordPress 3.0 has this nice feature which makes it possible to define the header image in the admin area. And if you upload a featured image on a post or page that is big enough then that Image can be used as the header image. Today I’m going to show you how to change your theme to add this feature. So lets start as always with the function.php file Add the following to it