<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>danielbachhuber &#187; WordPress</title>
	<atom:link href="http://danielbachhuber.com/tag/wordpress/feed/" rel="self" type="application/rss+xml" />
	<link>http://danielbachhuber.com</link>
	<description>wrangling code for Automattic&#039;s WordPress.com VIP</description>
	<lastBuildDate>Tue, 14 Feb 2012 00:05:56 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='danielbachhuber.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://1.gravatar.com/blavatar/185f1e7963728f352b72281297848b7f?s=96&#038;d=http%3A%2F%2Fs2.wp.com%2Fi%2Fbuttonw-com.png</url>
		<title>danielbachhuber &#187; WordPress</title>
		<link>http://danielbachhuber.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://danielbachhuber.com/osd.xml" title="danielbachhuber" />
	<atom:link rel='hub' href='http://danielbachhuber.com/?pushpress=hub'/>
		<item>
		<title>Include posts by matching authors in your search results</title>
		<link>http://danielbachhuber.com/2012/02/07/include-posts-by-matching-authors-in-your-search-results/</link>
		<comments>http://danielbachhuber.com/2012/02/07/include-posts-by-matching-authors-in-your-search-results/#comments</comments>
		<pubDate>Tue, 07 Feb 2012 17:26:22 +0000</pubDate>
		<dc:creator>Daniel Bachhuber</dc:creator>
				<category><![CDATA[posts]]></category>
		<category><![CDATA[code snippets]]></category>
		<category><![CDATA[search]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://danielbachhuber.com/?p=129750</guid>
		<description><![CDATA[Out of the box, WordPress&#8217; search isn&#8217;t that great. It only returns posts based on a LIKE query against the post title or post content. Often, you&#8217;ll want it to match against other data associated with your post, possibly including &#8230; <a href="http://danielbachhuber.com/2012/02/07/include-posts-by-matching-authors-in-your-search-results/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129750&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Out of the box, WordPress&#8217; search isn&#8217;t that great. It only returns posts based on a LIKE query against the post title or post content. Often, you&#8217;ll want it to match against other data associated with your post, possibly including the author, tags, post meta fields, etc. These queries can get complex to perform on the fly, however.</p>
<p>The following code snippet allows you to include posts by matching authors in your search results. We&#8217;re modifying any search queries to also include all posts whose author display name or user login matches the query. You can change this to be the author&#8217;s first name, last name, or other fields.</p>
<p><pre class="brush: php;">
/**
 * Include posts from authors in the search results where
 * either their display name or user login matches the query string
 *
 * @author danielbachhuber
 */
add_filter( 'posts_search', 'db_filter_authors_search' );
function db_filter_authors_search( $posts_search ) {

	// Don't modify the query at all if we're not on the search template
	// or if the LIKE is empty
	if ( !is_search() || empty( $posts_search ) )
		return $posts_search;

	global $wpdb;
	// Get all of the users of the blog and see if the search query matches either
	// the display name or the user login
	$all_users = get_users();
	$matching_users = array();
	foreach( $all_users as $blog_user ) {
		if ( false !== stripos( $blog_user-&gt;display_name, get_query_var('s') ) || false !== stripos( $blog_user-&gt;user_login, get_query_var('s') ) )
			$matching_users[] = $blog_user-&gt;ID;
	}
	// Don't modify the query if there aren't any matching users
	if ( empty( $matching_users ) )
		return $posts_search;
	// Take a slightly different approach than core where we want all of the posts from these authors
	$posts_search = rtrim( $posts_search, ') ' );
	$posts_search .= &quot;)) OR ( {$wpdb-&gt;posts}.post_author IN (&quot; . implode( ',', array_map( 'absint', $matching_users ) ) . &quot;)&quot;;
	return $posts_search . '))';
}
</pre></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/danielbachhuber.wordpress.com/129750/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/danielbachhuber.wordpress.com/129750/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/danielbachhuber.wordpress.com/129750/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/danielbachhuber.wordpress.com/129750/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/danielbachhuber.wordpress.com/129750/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/danielbachhuber.wordpress.com/129750/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/danielbachhuber.wordpress.com/129750/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/danielbachhuber.wordpress.com/129750/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/danielbachhuber.wordpress.com/129750/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/danielbachhuber.wordpress.com/129750/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/danielbachhuber.wordpress.com/129750/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/danielbachhuber.wordpress.com/129750/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/danielbachhuber.wordpress.com/129750/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/danielbachhuber.wordpress.com/129750/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129750&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://danielbachhuber.com/2012/02/07/include-posts-by-matching-authors-in-your-search-results/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c778bed467546a08fd2f3618a9fc9d4e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">danielbachhuber</media:title>
		</media:content>
	</item>
		<item>
		<title>Allowing authors to set co-authors</title>
		<link>http://danielbachhuber.com/2012/01/26/allowing-authors-to-set-co-authors/</link>
		<comments>http://danielbachhuber.com/2012/01/26/allowing-authors-to-set-co-authors/#comments</comments>
		<pubDate>Thu, 26 Jan 2012 17:40:56 +0000</pubDate>
		<dc:creator>Daniel Bachhuber</dc:creator>
				<category><![CDATA[posts]]></category>
		<category><![CDATA[Co-Authors Plus]]></category>
		<category><![CDATA[code snippets]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress plugins]]></category>
		<category><![CDATA[WordPress.org forums]]></category>

		<guid isPermaLink="false">http://danielbachhuber.com/?p=129690</guid>
		<description><![CDATA[In the WordPress.org forums, whoaloic asks: I have a site with multiple authors. I would like to allow authors who create a post or a page to give rights to other authors. For now, only administrator and editor can do &#8230; <a href="http://danielbachhuber.com/2012/01/26/allowing-authors-to-set-co-authors/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129690&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>In the WordPress.org forums, <a href="http://wordpress.org/support/topic/plugin-co-authors-plus-allow-authors-post-to-give-access-to-other-authors">whoaloic asks</a>:</p>
<blockquote><p>I have a site with multiple authors.<br />
I would like to allow authors who create a post or a page to give rights to other authors.<br />
For now, only administrator and editor can do that.<br />
Is there a solution?</p></blockquote>
<p>Yep, totally doable. By default, Co-Authors Plus defaults to &#8216;edit_others_posts&#8217; as the required cap for changing co-authors. With the following code snippet in your theme&#8217;s functions.php file, you can make that cap &#8216;publish_posts&#8217; instead (which authors and above usually have).</p>
<p><pre class="brush: php;">
/**
 * Filter the Co-Authors Plus current_user_can_set_authors() function
 * so that users with 'publish_posts' can set Co-Authors
 *
 * @author danielbachhuber
 *
 * @see https://github.com/danielbachhuber/Co-Authors-Plus/issues/8
 * @see http://wordpress.org/support/topic/plugin-co-authors-plus-allow-authors-post-to-give-access-to-other-authors
 */
add_filter( 'coauthors_plus_edit_authors', 'db_filter_coauthors_edit_cap' );
function db_filter_coauthors_edit_cap( $cap_result ) {
	global $coauthors_plus;

	$post_type = $coauthors_plus-&gt;get_current_post_type();
	if( ! $post_type ) return false;
	
	$post_type_object = get_post_type_object( $post_type );
	return current_user_can( $post_type_object-&gt;cap-&gt;publish_posts );
}
</pre></p>
<p>In preparing this snippet, I also opened a couple of issues in Github:</p>
<ul>
<li><a href="https://github.com/danielbachhuber/Co-Authors-Plus/issues/8">Allow authors to set co-authors by default</a> &#8211; I&#8217;m not sure why we restricted it to editors and admins originally. Also, the existing filter could use cleanup.</li>
<li><a href="https://github.com/danielbachhuber/Co-Authors-Plus/issues/7">Don&#8217;t show search box if user doesn&#8217;t have capability to change co-authors</a> &#8211; We should have a &#8220;locked&#8221; UI if the user doesn&#8217;t have the appropriate cap</li>
</ul>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/danielbachhuber.wordpress.com/129690/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/danielbachhuber.wordpress.com/129690/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/danielbachhuber.wordpress.com/129690/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/danielbachhuber.wordpress.com/129690/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/danielbachhuber.wordpress.com/129690/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/danielbachhuber.wordpress.com/129690/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/danielbachhuber.wordpress.com/129690/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/danielbachhuber.wordpress.com/129690/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/danielbachhuber.wordpress.com/129690/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/danielbachhuber.wordpress.com/129690/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/danielbachhuber.wordpress.com/129690/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/danielbachhuber.wordpress.com/129690/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/danielbachhuber.wordpress.com/129690/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/danielbachhuber.wordpress.com/129690/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129690&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://danielbachhuber.com/2012/01/26/allowing-authors-to-set-co-authors/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c778bed467546a08fd2f3618a9fc9d4e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">danielbachhuber</media:title>
		</media:content>
	</item>
		<item>
		<title>Intensive WordPress VIP Developer Training Workshop: March 2012</title>
		<link>http://danielbachhuber.com/2012/01/23/intensive-wordpress-vip-developer-training-workshop-march-2012/</link>
		<comments>http://danielbachhuber.com/2012/01/23/intensive-wordpress-vip-developer-training-workshop-march-2012/#comments</comments>
		<pubDate>Mon, 23 Jan 2012 21:28:58 +0000</pubDate>
		<dc:creator>Daniel Bachhuber</dc:creator>
				<category><![CDATA[asides]]></category>
		<category><![CDATA[Automattic]]></category>
		<category><![CDATA[California]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress.com VIP]]></category>
		<category><![CDATA[workshops]]></category>

		<guid isPermaLink="false">http://danielbachhuber.com/?p=129676</guid>
		<description><![CDATA[Intensive WordPress VIP Developer Training Workshop: March 2012. Come join us! Take three days in California&#8217;s wine country to learn about coding standards, caching, optimization and other high performance topics.<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129676&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://vip.wordpress.com/2012/01/16/intensive-wordpress-vip-developer-training-workshop-march-2012/">Intensive WordPress VIP Developer Training Workshop: March 2012</a>. Come join us! Take three days in California&#8217;s wine country to learn about coding standards, caching, optimization and other high performance topics.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/danielbachhuber.wordpress.com/129676/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/danielbachhuber.wordpress.com/129676/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/danielbachhuber.wordpress.com/129676/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/danielbachhuber.wordpress.com/129676/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/danielbachhuber.wordpress.com/129676/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/danielbachhuber.wordpress.com/129676/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/danielbachhuber.wordpress.com/129676/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/danielbachhuber.wordpress.com/129676/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/danielbachhuber.wordpress.com/129676/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/danielbachhuber.wordpress.com/129676/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/danielbachhuber.wordpress.com/129676/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/danielbachhuber.wordpress.com/129676/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/danielbachhuber.wordpress.com/129676/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/danielbachhuber.wordpress.com/129676/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129676&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://danielbachhuber.com/2012/01/23/intensive-wordpress-vip-developer-training-workshop-march-2012/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c778bed467546a08fd2f3618a9fc9d4e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">danielbachhuber</media:title>
		</media:content>
	</item>
		<item>
		<title>New York Times releases code to help journalists collaborate on WordPress, other platforms</title>
		<link>http://danielbachhuber.com/2012/01/23/new-york-times-releases-code-to-help-journalists-collaborate-on-wordpress-other-platforms/</link>
		<comments>http://danielbachhuber.com/2012/01/23/new-york-times-releases-code-to-help-journalists-collaborate-on-wordpress-other-platforms/#comments</comments>
		<pubDate>Mon, 23 Jan 2012 18:22:45 +0000</pubDate>
		<dc:creator>Daniel Bachhuber</dc:creator>
				<category><![CDATA[asides]]></category>
		<category><![CDATA[New York Times]]></category>
		<category><![CDATA[open source]]></category>
		<category><![CDATA[publishing]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress plugins]]></category>
		<category><![CDATA[writing]]></category>

		<guid isPermaLink="false">http://danielbachhuber.com/?p=129674</guid>
		<description><![CDATA[New York Times releases code to help journalists collaborate on WordPress, other platforms. Track changes within the WordPress editor. Code is available on Github; it would be awesome to see this support realtime collaborative editing too. (via Steve Myers)<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129674&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.poynter.org/latest-news/top-stories/160460/new-york-times-releases-code-to-help-journalists-collaborate-on-wordpress-other-platforms/">New York Times releases code to help journalists collaborate on WordPress, other platforms</a>. Track changes within the WordPress editor. Code is <a href="https://github.com/nytd/ice">available on Github</a>; it would be awesome to see this support realtime collaborative editing too. <em>(via Steve Myers)</em></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/danielbachhuber.wordpress.com/129674/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/danielbachhuber.wordpress.com/129674/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/danielbachhuber.wordpress.com/129674/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/danielbachhuber.wordpress.com/129674/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/danielbachhuber.wordpress.com/129674/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/danielbachhuber.wordpress.com/129674/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/danielbachhuber.wordpress.com/129674/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/danielbachhuber.wordpress.com/129674/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/danielbachhuber.wordpress.com/129674/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/danielbachhuber.wordpress.com/129674/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/danielbachhuber.wordpress.com/129674/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/danielbachhuber.wordpress.com/129674/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/danielbachhuber.wordpress.com/129674/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/danielbachhuber.wordpress.com/129674/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129674&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://danielbachhuber.com/2012/01/23/new-york-times-releases-code-to-help-journalists-collaborate-on-wordpress-other-platforms/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c778bed467546a08fd2f3618a9fc9d4e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">danielbachhuber</media:title>
		</media:content>
	</item>
		<item>
		<title>Show biographies for co-authors at the end of your post</title>
		<link>http://danielbachhuber.com/2012/01/22/show-biographies-for-co-authors-at-the-end-of-your-post/</link>
		<comments>http://danielbachhuber.com/2012/01/22/show-biographies-for-co-authors-at-the-end-of-your-post/#comments</comments>
		<pubDate>Mon, 23 Jan 2012 03:50:07 +0000</pubDate>
		<dc:creator>Daniel Bachhuber</dc:creator>
				<category><![CDATA[posts]]></category>
		<category><![CDATA[Co-Authors Plus]]></category>
		<category><![CDATA[code snippets]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress.org forums]]></category>

		<guid isPermaLink="false">http://danielbachhuber.com/?p=129668</guid>
		<description><![CDATA[In the WordPress.org forums, doubleedesign says: I want to add the authors&#8217; biographies to the end of each post. Awesome&#8230; it&#8217;s pretty simple to do. Conceptually, what we need to do is load our co-authors, and then loop through printing &#8230; <a href="http://danielbachhuber.com/2012/01/22/show-biographies-for-co-authors-at-the-end-of-your-post/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129668&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>In the WordPress.org forums, <a href="http://wordpress.org/support/topic/co-authors-plus-author-bios-on-single-posts?replies=1">doubleedesign says</a>:</p>
<blockquote><p>I want to add the authors&#8217; biographies to the end of each post.</p></blockquote>
<p>Awesome&#8230; it&#8217;s pretty simple to do. Conceptually, what we need to do is load our co-authors, and then loop through printing the relevant information for each one.</p>
<p>You&#8217;ll want to put the following code snippet within The Loop in any template you&#8217;d like the bios to appear.</p>
<p><pre class="brush: php;">
/**
 * Show multiple Co-Author biography fields at the bottom of a single post 
 * This snippet should be placed within The Loop
 */
if ( class_exists( 'coauthors_plus' ) ) {
	// Get the Co-Authors for the post
	$co_authors = get_coauthors();
	// For each Co-Author, echo a wrapper div, their name, and their bio if they have one
	foreach ( $co_authors as $key =&gt; $co_author ) {
		$co_author_classes = array(
			'co-author-wrap',
			'co-author-number-' . ( $key + 1 ),
		);
		echo '&lt;div class=&quot;' . implode( ' ', $co_author_classes ) . '&quot;&gt;';
		echo '&lt;h4 class=&quot;co-author-display-name&quot;&gt;' . $co_author-&gt;display_name . '&lt;/h4&gt;';
		// Only print the description if the description exists
		if ( $description = get_the_author_meta( 'description', $co_author-&gt;ID ) )
			echo '&lt;p class=&quot;co-author-bio&quot;&gt;' . $description . '&lt;/p&gt;';
		echo '&lt;/div&gt;';
	}
}
</pre></p>
<p>If you&#8217;d like other co-author details to appear as well, like their avatar for instance, you can modify the output within the foreach loop.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/danielbachhuber.wordpress.com/129668/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/danielbachhuber.wordpress.com/129668/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/danielbachhuber.wordpress.com/129668/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/danielbachhuber.wordpress.com/129668/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/danielbachhuber.wordpress.com/129668/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/danielbachhuber.wordpress.com/129668/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/danielbachhuber.wordpress.com/129668/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/danielbachhuber.wordpress.com/129668/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/danielbachhuber.wordpress.com/129668/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/danielbachhuber.wordpress.com/129668/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/danielbachhuber.wordpress.com/129668/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/danielbachhuber.wordpress.com/129668/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/danielbachhuber.wordpress.com/129668/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/danielbachhuber.wordpress.com/129668/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129668&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://danielbachhuber.com/2012/01/22/show-biographies-for-co-authors-at-the-end-of-your-post/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c778bed467546a08fd2f3618a9fc9d4e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">danielbachhuber</media:title>
		</media:content>
	</item>
		<item>
		<title>Today&#8217;s two WordPress.com VIP launches: PandoDaily and Grist</title>
		<link>http://danielbachhuber.com/2012/01/16/todays-two-wordpress-com-vip-launches-pandodaily-and-grist/</link>
		<comments>http://danielbachhuber.com/2012/01/16/todays-two-wordpress-com-vip-launches-pandodaily-and-grist/#comments</comments>
		<pubDate>Tue, 17 Jan 2012 03:47:46 +0000</pubDate>
		<dc:creator>Daniel Bachhuber</dc:creator>
				<category><![CDATA[posts]]></category>
		<category><![CDATA[content management systems]]></category>
		<category><![CDATA[Grist]]></category>
		<category><![CDATA[launches]]></category>
		<category><![CDATA[PandoDaily]]></category>
		<category><![CDATA[publishing]]></category>
		<category><![CDATA[technology]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress.com VIP]]></category>

		<guid isPermaLink="false">http://danielbachhuber.com/?p=129639</guid>
		<description><![CDATA[Today, MLK day even, two new sites launched on WordPress.com VIP that I&#8217;m personally pretty excited about. PandoDaily PandoDaily is a brand new tech site started by Sarah Lacy, former senior editor at TechCrunch. From her announcement post: We have one goal &#8230; <a href="http://danielbachhuber.com/2012/01/16/todays-two-wordpress-com-vip-launches-pandodaily-and-grist/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129639&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Today, MLK day even, two new sites launched on <a href="http://vip.wordpress.com/">WordPress.com VIP</a> that I&#8217;m personally pretty excited about.</p>
<h3>PandoDaily</h3>
<p><a href="http://pandodaily.com/"><img class="aligncenter size-full wp-image-129640" title="PandoDaily on launch day" src="http://danielbachhuber.files.wordpress.com/2012/01/pandodaily.jpg?w=584&#038;h=412" alt="" width="584" height="412" /></a></p>
<p><a href="http://pandodaily.com/">PandoDaily</a> is a brand new tech site started by Sarah Lacy, former senior editor at TechCrunch. From <a href="http://pandodaily.com/2012/01/16/why-i-started-pandodaily/">her announcement post</a>:</p>
<blockquote><p><strong>We have one goal here at PandoDaily: To be the site-of-record for that startup root-system and everything that springs up from it, cycle-after-cycle.</strong> That sounds simple but it’ll be incredibly hard to pull off. It’s not something we accomplish on day one or even day 300. It’s something we accomplish by waking up every single day and writing the best stuff we can, and continually adding like-minded staffers who have the passion, drive and talent to do the same.</p></blockquote>
<p>So&#8230; this sounds like a newer, better, and fresher TechCrunch starting from scratch. And she&#8217;s recruited <a href="https://twitter.com/#!/arrington">Michael Arrington</a>, <a href="https://twitter.com/#!/parislemon">MG Siegler</a>, <a href="https://twitter.com/#!/paulcarr">Paul Carr</a> and <a href="https://twitter.com/#!/fmanjoo">Farhad Manjoo</a> as regular contributors. Props to <a href="http://sara-cannon.com/">Sara Cannon</a> for pulling off the design.</p>
<h3>Grist</h3>
<p><a href="http://grist.org/"><img class="alignnone size-full wp-image-129641" title="Grist screenshot from launch day" src="http://danielbachhuber.files.wordpress.com/2012/01/grist.jpg?w=584&#038;h=408" alt="" width="584" height="408" /></a></p>
<p><a href="http://grist.org/">Grist</a>, a non-profit environmental news publication, is near and dear to my heart. It&#8217;s why I&#8217;m on the technology side of publishing instead of photographing in the third world. In summer 2007, I worked an awesome web production internship where, in exchange for a bit of copy and pasting into the CMS, I had the freedom to explore publishing on the web and to start developing my skills. That was back in the days of <a href="http://bricolagecms.org/">Bricolage</a>; Grist has since been on <a href="http://expressionengine.com/">ExpressionEngine</a>. Props to <a href="http://stkywll.com/">Matt Perry</a> and <a href="http://twitter.com/natebot">Nathan Letsinger</a> for making the switch happen (and to the Otto and Nacin show for their support).</p>
<p>Want to help publishers kick ass with WordPress? Come join my team — <a href="http://automattic.com/work-with-us/">we&#8217;re hiring</a>.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/danielbachhuber.wordpress.com/129639/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/danielbachhuber.wordpress.com/129639/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/danielbachhuber.wordpress.com/129639/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/danielbachhuber.wordpress.com/129639/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/danielbachhuber.wordpress.com/129639/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/danielbachhuber.wordpress.com/129639/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/danielbachhuber.wordpress.com/129639/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/danielbachhuber.wordpress.com/129639/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/danielbachhuber.wordpress.com/129639/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/danielbachhuber.wordpress.com/129639/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/danielbachhuber.wordpress.com/129639/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/danielbachhuber.wordpress.com/129639/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/danielbachhuber.wordpress.com/129639/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/danielbachhuber.wordpress.com/129639/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129639&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://danielbachhuber.com/2012/01/16/todays-two-wordpress-com-vip-launches-pandodaily-and-grist/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c778bed467546a08fd2f3618a9fc9d4e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">danielbachhuber</media:title>
		</media:content>

		<media:content url="http://danielbachhuber.files.wordpress.com/2012/01/pandodaily.jpg" medium="image">
			<media:title type="html">PandoDaily on launch day</media:title>
		</media:content>

		<media:content url="http://danielbachhuber.files.wordpress.com/2012/01/grist.jpg" medium="image">
			<media:title type="html">Grist screenshot from launch day</media:title>
		</media:content>
	</item>
		<item>
		<title>User Switching « WordPress Plugins</title>
		<link>http://danielbachhuber.com/2012/01/09/user-switching-wordpress-plugins/</link>
		<comments>http://danielbachhuber.com/2012/01/09/user-switching-wordpress-plugins/#comments</comments>
		<pubDate>Mon, 09 Jan 2012 17:20:35 +0000</pubDate>
		<dc:creator>Daniel Bachhuber</dc:creator>
				<category><![CDATA[asides]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress plugins]]></category>
		<category><![CDATA[WPCandy]]></category>

		<guid isPermaLink="false">http://danielbachhuber.com/?p=129623</guid>
		<description><![CDATA[User Switching « WordPress Plugins. Quickly switch between user accounts. Super useful when populating dummy content for your test website. (via WPCandy)<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129623&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://wordpress.org/extend/plugins/user-switching/">User Switching « WordPress Plugins</a>. Quickly switch between user accounts. Super useful when populating dummy content for your test website. <em>(via <a href="http://wpcandy.com/broadcasts/the-sweet-plugin/user-switching">WPCandy</a>)</em></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/danielbachhuber.wordpress.com/129623/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/danielbachhuber.wordpress.com/129623/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/danielbachhuber.wordpress.com/129623/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/danielbachhuber.wordpress.com/129623/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/danielbachhuber.wordpress.com/129623/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/danielbachhuber.wordpress.com/129623/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/danielbachhuber.wordpress.com/129623/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/danielbachhuber.wordpress.com/129623/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/danielbachhuber.wordpress.com/129623/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/danielbachhuber.wordpress.com/129623/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/danielbachhuber.wordpress.com/129623/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/danielbachhuber.wordpress.com/129623/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/danielbachhuber.wordpress.com/129623/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/danielbachhuber.wordpress.com/129623/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129623&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://danielbachhuber.com/2012/01/09/user-switching-wordpress-plugins/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c778bed467546a08fd2f3618a9fc9d4e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">danielbachhuber</media:title>
		</media:content>
	</item>
		<item>
		<title>Open Web FTW</title>
		<link>http://danielbachhuber.com/2011/12/28/open-web-ftw/</link>
		<comments>http://danielbachhuber.com/2011/12/28/open-web-ftw/#comments</comments>
		<pubDate>Wed, 28 Dec 2011 17:55:07 +0000</pubDate>
		<dc:creator>Daniel Bachhuber</dc:creator>
				<category><![CDATA[quotes]]></category>
		<category><![CDATA[Matt Mullenweg]]></category>
		<category><![CDATA[open source]]></category>
		<category><![CDATA[philosophy]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://danielbachhuber.com/?p=129572</guid>
		<description><![CDATA[I worry about the independent web. I worry about the content creators, and I worry that if 100 percent of the distribution of everything starts to go through just a few websites, that kills the vibrancy. A few years ago, &#8230; <a href="http://danielbachhuber.com/2011/12/28/open-web-ftw/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129572&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<blockquote><p>I worry about the independent web. I worry about the content creators, and I worry that if 100 percent of the distribution of everything starts to go through just a few websites, that kills the vibrancy.</p>
<p>A few years ago, Google started favoring some of their own websites over others. They left a path of scorched earth through many prominent businesses and publishers. Facebook hasn’t done that, but they could. And I think that would be bad for the web as a whole.</p>
<p>As things like Facebook’s news feed become ever more ingrained in our lives, the knobs they turn are hugely influential. For a year now, I’ve said scripting is the new literacy. That’s something I strongly believe. In Douglas Rushkoff’s latest book, he talks about “program or be programmed.” That is, if you’re not in control of your inputs, you’re not really in control of your outputs either. You’re just a reactionary force.</p>
<p>[...]</p>
<p>The Internet needs a strong, independent platform for those of us who don’t want to be at the mercy of someone else’s domain. I like to think that if we didn’t create WordPress something else that looks a lot like it would exist. I think Open Source is kind of like our Bill of Rights. It’s our Constitution. If we’re not true to that, nothing else matters.</p></blockquote>
<p>Matt Mullenweg — <a href="http://gigaom.com/2011/12/27/12-for-2012/3/">Open Web FTW</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/danielbachhuber.wordpress.com/129572/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/danielbachhuber.wordpress.com/129572/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/danielbachhuber.wordpress.com/129572/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/danielbachhuber.wordpress.com/129572/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/danielbachhuber.wordpress.com/129572/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/danielbachhuber.wordpress.com/129572/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/danielbachhuber.wordpress.com/129572/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/danielbachhuber.wordpress.com/129572/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/danielbachhuber.wordpress.com/129572/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/danielbachhuber.wordpress.com/129572/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/danielbachhuber.wordpress.com/129572/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/danielbachhuber.wordpress.com/129572/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/danielbachhuber.wordpress.com/129572/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/danielbachhuber.wordpress.com/129572/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129572&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://danielbachhuber.com/2011/12/28/open-web-ftw/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c778bed467546a08fd2f3618a9fc9d4e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">danielbachhuber</media:title>
		</media:content>
	</item>
		<item>
		<title>Co-Authors Plus v2.6: Search user&#8217;s display names, change byline order and more</title>
		<link>http://danielbachhuber.com/2011/12/22/co-authors-plus-v2-6-search-users-display-names-change-byline-order-and-more/</link>
		<comments>http://danielbachhuber.com/2011/12/22/co-authors-plus-v2-6-search-users-display-names-change-byline-order-and-more/#comments</comments>
		<pubDate>Fri, 23 Dec 2011 04:39:38 +0000</pubDate>
		<dc:creator>Daniel Bachhuber</dc:creator>
				<category><![CDATA[posts]]></category>
		<category><![CDATA[Co-Authors Plus]]></category>
		<category><![CDATA[open source]]></category>
		<category><![CDATA[projects]]></category>
		<category><![CDATA[publishing]]></category>
		<category><![CDATA[releases]]></category>
		<category><![CDATA[Russell Heimlich]]></category>
		<category><![CDATA[v2.6]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress plugins]]></category>
		<category><![CDATA[WordPress.com VIP]]></category>

		<guid isPermaLink="false">http://danielbachhuber.com/?p=129434</guid>
		<description><![CDATA[Co-Authors Plus makes it easy to add multiple bylines to a given post, and has full support for custom post types. Out this evening, v2.6 has the following improvements: Sortable authors — drag and drop the order of the authors &#8230; <a href="http://danielbachhuber.com/2011/12/22/co-authors-plus-v2-6-search-users-display-names-change-byline-order-and-more/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129434&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://wordpress.org/extend/plugins/co-authors-plus/">Co-Authors Plus</a> makes it easy to add multiple bylines to a given post, and has full support for custom post types. Out this evening, v2.6 has the following improvements:</p>
<ul>
<li>Sortable authors — drag and drop the order of the authors as you&#8217;d like them to appear</li>
<li>Search for authors by display name so you can easily add bylines by first or last name</li>
<li>Option to remove the first author when there are two or more listed</li>
<li>More reliably generates the published post count for each user</li>
</ul>
<p>Thanks to <a href="http://wordpress.org/tags/co-authors-plus?forum_id=10">those in the forum</a> who provided feedback and special thanks to <a href="http://www.russellheimlich.com/">Russell Heimlich</a> for <a href="http://plugins.trac.wordpress.org/ticket/1438">his contributions</a> with sortable authors. If you feel like giving back, there are a <a href="http://plugins.trac.wordpress.org/query?status=%21closed&amp;keywords=~co-authors-plus">few tickets open we&#8217;d love patches for</a>. In particular, <a href="http://plugins.trac.wordpress.org/ticket/1440">guest bylines</a> would be pretty neat. I have a possible direction you can go if you&#8217;re looking for inspiration.</p>
<p>For our WordPress.com VIPs, this release will be available in the shared plugins directory in just a moment.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/danielbachhuber.wordpress.com/129434/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/danielbachhuber.wordpress.com/129434/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/danielbachhuber.wordpress.com/129434/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/danielbachhuber.wordpress.com/129434/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/danielbachhuber.wordpress.com/129434/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/danielbachhuber.wordpress.com/129434/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/danielbachhuber.wordpress.com/129434/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/danielbachhuber.wordpress.com/129434/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/danielbachhuber.wordpress.com/129434/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/danielbachhuber.wordpress.com/129434/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/danielbachhuber.wordpress.com/129434/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/danielbachhuber.wordpress.com/129434/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/danielbachhuber.wordpress.com/129434/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/danielbachhuber.wordpress.com/129434/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129434&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://danielbachhuber.com/2011/12/22/co-authors-plus-v2-6-search-users-display-names-change-byline-order-and-more/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c778bed467546a08fd2f3618a9fc9d4e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">danielbachhuber</media:title>
		</media:content>
	</item>
		<item>
		<title>Show matching terms in your search results</title>
		<link>http://danielbachhuber.com/2011/12/18/show-matching-terms-in-your-search-results/</link>
		<comments>http://danielbachhuber.com/2011/12/18/show-matching-terms-in-your-search-results/#comments</comments>
		<pubDate>Mon, 19 Dec 2011 02:11:43 +0000</pubDate>
		<dc:creator>Daniel Bachhuber</dc:creator>
				<category><![CDATA[posts]]></category>
		<category><![CDATA[code snippets]]></category>
		<category><![CDATA[search]]></category>
		<category><![CDATA[user experience]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://danielbachhuber.com/?p=129414</guid>
		<description><![CDATA[WordPress&#8217; internal search isn&#8217;t all that great out of the box, as I&#8217;ve discussed before. For instance, tags and categories aren&#8217;t included in the search query; as such, if your post is tagged &#8220;apple&#8221;, but there is no mention of &#8230; <a href="http://danielbachhuber.com/2011/12/18/show-matching-terms-in-your-search-results/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129414&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>WordPress&#8217; internal search isn&#8217;t all that great out of the box, <a href="http://danielbachhuber.com/2011/01/24/researching-better-search-functionality-for-the-cuny-j-school-network/">as I&#8217;ve discussed before</a>. For instance, tags and categories aren&#8217;t included in the search query; as such, if your post is tagged &#8220;apple&#8221;, but there is no mention of &#8220;apple&#8221; in the title or post content, the post won&#8217;t be included in your search results.</p>
<p>One partial workaround is to search taxonomy terms against your query and include those in your results. <a href="http://danielbachhuber.com/2011/07/12/improvements-in-tech-website-v0-4-search-query-highlighting-suggested-topics-and-improved-topical-landing-pages/">I did this previously</a> with the CUNY J-School&#8217;s tech website:</p>
<p><img src="http://danielbachhuber.files.wordpress.com/2011/12/terms-in-the-search-results.jpg?w=584&#038;h=285" alt="" title="Terms in the search results" width="584" height="285" class="alignnone size-full wp-image-129417" /></p>
<p>You can have something similar with the code snippet below.</p>
<p><pre class="brush: php;">&lt;?php
/**
 * Show matching terms for a given search query
 * Best placed under the_search_form() in search.php 
 */
global $wp_query;
// Only show the matching terms on the first page of results
if ( $wp_query-&gt;query_vars['paged'] &lt;= 1 ) {
	$args = array(
		'search' =&gt; get_search_query(),
		'orderby' =&gt; 'none',
	);
	// You can change the first argument to an array of whatever taxonomies you want to search against
	$matching_terms = get_terms( array( 'post_tag', 'category' ), $args );
	if ( count( $matching_terms ) ) {					
		echo '&lt;div class=&quot;all-matching-terms&quot;&gt;Looking for? ';
		$all_terms = '';
		foreach ( $matching_terms as $matching_term ) {
			$all_terms .= '&lt;a ';
			if ( $matching_term-&gt;description )
				$all_terms .= 'title=&quot;' . esc_attr( $matching_term-&gt;description ) . '&quot; ';
			$all_terms .= 'href=&quot;' . esc_url( get_term_link( $matching_term, $matching_term-&gt;taxonomy ) ) . '&quot;&gt;' . esc_html( $matching_term-&gt;name ) . '&lt;/a&gt;, ';
		}
		echo rtrim( $all_terms, ', ' );
		echo '&lt;/div&gt;';
	}
}</pre></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/danielbachhuber.wordpress.com/129414/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/danielbachhuber.wordpress.com/129414/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/danielbachhuber.wordpress.com/129414/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/danielbachhuber.wordpress.com/129414/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/danielbachhuber.wordpress.com/129414/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/danielbachhuber.wordpress.com/129414/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/danielbachhuber.wordpress.com/129414/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/danielbachhuber.wordpress.com/129414/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/danielbachhuber.wordpress.com/129414/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/danielbachhuber.wordpress.com/129414/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/danielbachhuber.wordpress.com/129414/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/danielbachhuber.wordpress.com/129414/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/danielbachhuber.wordpress.com/129414/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/danielbachhuber.wordpress.com/129414/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=danielbachhuber.com&amp;blog=16096444&amp;post=129414&amp;subd=danielbachhuber&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://danielbachhuber.com/2011/12/18/show-matching-terms-in-your-search-results/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c778bed467546a08fd2f3618a9fc9d4e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">danielbachhuber</media:title>
		</media:content>

		<media:content url="http://danielbachhuber.files.wordpress.com/2011/12/terms-in-the-search-results.jpg" medium="image">
			<media:title type="html">Terms in the search results</media:title>
		</media:content>
	</item>
	</channel>
</rss>
