<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Peter Shilling</title>
	
	<link>http://www.shilling.id.au</link>
	<description>WordPress, Digital Marketing, Music &amp; Photos</description>
	<lastBuildDate>Mon, 20 May 2013 11:29:15 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/PeterShilling" /><feedburner:info uri="petershilling" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><feedburner:emailServiceId>PeterShilling</feedburner:emailServiceId><feedburner:feedburnerHostname>http://feedburner.google.com</feedburner:feedburnerHostname><item>
		<title>WordPress comment spam</title>
		<link>http://feedproxy.google.com/~r/PeterShilling/~3/aUS9eZ6kJAo/</link>
		<comments>http://www.shilling.id.au/2013/05/20/wordpress-comment-spam/#comments</comments>
		<pubDate>Mon, 20 May 2013 11:27:34 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[Wordpress Tips]]></category>

		<guid isPermaLink="false">http://www.shilling.id.au/?p=1822</guid>
		<description><![CDATA[I'm drowning in comment spam! Help me by suggesting a good tool that you know of that helps reduce the amount of spam that WordPress sites get.]]></description>
				<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:right;height:30px;'><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http://www.shilling.id.au/2013/05/20/wordpress-comment-spam/' data-shr_title='WordPress+comment+spam'></a><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http://www.shilling.id.au/2013/05/20/wordpress-comment-spam/' data-shr_title='WordPress+comment+spam'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetTop Automatic --><p>So I manage a lot of WordPress sites and all of them suffer from comment spam at some level. What the heck has happened in the past couple of months? Each morning the old inbox is full of emails from the plethora of WordPress sites asking to validate the comments, &#8220;is this a genuine comment or is it just junk?&#8221;</p>
<p>Most of the time &#8211; yup it&#8217;s junk.</p>
<p>So I took to the Akismet stats screen in the WordPress dashboard to see if there actually was an increase or am I getting old and grumpy?</p>
<p>Check out the stats from just two sites.</p>
<p><a href="http://www.shilling.id.au/wp-content/uploads/2013/05/WordPress-comment-spam-2.png"><img class="alignnone size-medium wp-image-1823" alt="WordPress-comment-spam-2" src="http://www.shilling.id.au/wp-content/uploads/2013/05/WordPress-comment-spam-2-300x102.png" width="300" height="102" /></a></p>
<p><a href="http://www.shilling.id.au/wp-content/uploads/2013/05/wordPress-comment-spam-1.png"><img class="alignnone size-medium wp-image-1824" alt="wordPress-comment-spam-1" src="http://www.shilling.id.au/wp-content/uploads/2013/05/wordPress-comment-spam-1-300x92.png" width="300" height="92" /></a></p>
<p>Click to view these guys larger in all of their spammy glory!</p>
<p>At least it appears that the spam has peaked! I&#8217;ve not been using much other than Akismet, if you&#8217;re reading this and have a suggestion of a good WordPress plugin that somehow blocks or deters this kind of spam, leave me a comment (ironic huh?).</p>
<div class="shr-publisher-1822"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic --><img src="http://feeds.feedburner.com/~r/PeterShilling/~4/aUS9eZ6kJAo" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.shilling.id.au/2013/05/20/wordpress-comment-spam/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.shilling.id.au/2013/05/20/wordpress-comment-spam/</feedburner:origLink></item>
		<item>
		<title>Gravity Forms Notifications: route to an email that is stored in a custom field</title>
		<link>http://feedproxy.google.com/~r/PeterShilling/~3/VHh3fp-48so/</link>
		<comments>http://www.shilling.id.au/2013/04/08/gravity-forms-notifications-route-to-an-email-that-is-stored-in-a-custom-field/#comments</comments>
		<pubDate>Mon, 08 Apr 2013 05:04:05 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[WordPress Code]]></category>
		<category><![CDATA[gravity forms]]></category>

		<guid isPermaLink="false">http://www.shilling.id.au/?p=1796</guid>
		<description><![CDATA[Here's a quick PHP snippet that shows you how to alter the notification TO field based to send to an email address stored in a custom field]]></description>
				<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:right;height:30px;'><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http://www.shilling.id.au/2013/04/08/gravity-forms-notifications-route-to-an-email-that-is-stored-in-a-custom-field/' data-shr_title='Gravity+Forms+Notifications%3A+route+to+an+email+that+is+stored+in+a+custom+field'></a><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http://www.shilling.id.au/2013/04/08/gravity-forms-notifications-route-to-an-email-that-is-stored-in-a-custom-field/' data-shr_title='Gravity+Forms+Notifications%3A+route+to+an+email+that+is+stored+in+a+custom+field'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetTop Automatic --><p>This is a little snippet that I put together today that I thought would be of interest to others (and me probably in another project soon)</p>
<p>Gravity Forms has changed some of the code around notification hooks in 1.7 and higher, there is a new hook &#8220;gform_notification&#8221; that is used to interrupt and alter the notifications that are being send after a form is filled in.</p>
<p>So, here&#8217;s the situation. You have a post or a custom post type that has a custom field &#8220;emailaddress&#8221;. When the form is filled in you&#8217;d like the notification to go to that email address instead of the normal one listed in the notification section of the form.</p>
<p>I came across this while working on a conveyancer web site, each conveyancer is setup as post in a custom post type with their email, when an enquiry is made the notification is sent directly to them&#8230; Easy huh!</p>
<p>So here&#8217;s the code, make sure you change the _7 to the form ID that is relevant to your setup and of course if your email address is setup in a field name something other than &#8220;emailaddres&#8221; well you can change that too.</p>
<p>Enjoy!</p>
<pre class="brush: php; title: ; notranslate">
add_filter( 'gform_notification_7', 'route_notification', 1, 2 );

function route_notification($notification, $form , $entry) {
	global $post;
	$email_to = get_post_meta($post-&gt;ID, 'emailaddress', true);
	if ($email_to){
		$notification['to'] = $email_to;	
	}
	return $notification ;
}

</pre>
<div class="shr-publisher-1796"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic --><img src="http://feeds.feedburner.com/~r/PeterShilling/~4/VHh3fp-48so" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.shilling.id.au/2013/04/08/gravity-forms-notifications-route-to-an-email-that-is-stored-in-a-custom-field/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.shilling.id.au/2013/04/08/gravity-forms-notifications-route-to-an-email-that-is-stored-in-a-custom-field/</feedburner:origLink></item>
		<item>
		<title>Making WordPress menus with pages and child pages</title>
		<link>http://feedproxy.google.com/~r/PeterShilling/~3/5quAcVxtpsQ/</link>
		<comments>http://www.shilling.id.au/2013/03/15/making-wordpress-menus-with-pages-and-child-pages/#comments</comments>
		<pubDate>Fri, 15 Mar 2013 06:38:29 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[WordPress Plugin]]></category>
		<category><![CDATA[WP Child Page Menu]]></category>

		<guid isPermaLink="false">http://www.shilling.id.au/?p=1786</guid>
		<description><![CDATA[Need to create a smart WordPress menu where using Pages and Child Pages? We've just completed a WordPress plugin that makes the whole thing a few mouse clicks]]></description>
				<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:right;height:30px;'><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http://www.shilling.id.au/2013/03/15/making-wordpress-menus-with-pages-and-child-pages/' data-shr_title='Making+WordPress+menus+with+pages+and+child+pages'></a><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http://www.shilling.id.au/2013/03/15/making-wordpress-menus-with-pages-and-child-pages/' data-shr_title='Making+WordPress+menus+with+pages+and+child+pages'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetTop Automatic --><p>At the DMA when building WordPress sites, we regularly come across things that we do over again. Building custom menu is certainly one of those things.</p>
<p>One of the common requirements we&#8217;ve met is a menu that works with parent and child pages, when a visitor is on a child page the menu should show all of the pages in that section but not others.</p>
<p>So recently we&#8217;ve set about turning our code into a new plugin for WordPress and not it&#8217;s available for others to use!</p>
<p>If you&#8217;re interested in such a plugin, check out the <a href="http://helpforwp.com/plugins/custom-post-wp-gallery/">info here</a>, there&#8217;s even a short video that shows you a demo.</p>
<div class="shr-publisher-1786"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic --><img src="http://feeds.feedburner.com/~r/PeterShilling/~4/5quAcVxtpsQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.shilling.id.au/2013/03/15/making-wordpress-menus-with-pages-and-child-pages/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://www.shilling.id.au/2013/03/15/making-wordpress-menus-with-pages-and-child-pages/</feedburner:origLink></item>
		<item>
		<title>Learning Gravity Forms – a new eBook</title>
		<link>http://feedproxy.google.com/~r/PeterShilling/~3/9rFPlrPwzsw/</link>
		<comments>http://www.shilling.id.au/2013/01/29/learning-gravity-forms-a-new-ebook/#comments</comments>
		<pubDate>Tue, 29 Jan 2013 02:58:18 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[Wordpress Tips]]></category>
		<category><![CDATA[gravity forms]]></category>

		<guid isPermaLink="false">http://www.shilling.id.au/?p=1725</guid>
		<description><![CDATA[Published this week is a new eBook that I have authored. "Learning Gravity forms" is written in plain English and is aimed at users of the WordPress plugin Gravity Forms who would like to master the plugin]]></description>
				<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:right;height:30px;'><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http://www.shilling.id.au/2013/01/29/learning-gravity-forms-a-new-ebook/' data-shr_title='Learning+Gravity+Forms+-+a+new+eBook'></a><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http://www.shilling.id.au/2013/01/29/learning-gravity-forms-a-new-ebook/' data-shr_title='Learning+Gravity+Forms+-+a+new+eBook'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetTop Automatic --><p><img class="alignright size-full wp-image-1732" alt="Gravity Forms Training eBook" src="http://www.shilling.id.au/wp-content/uploads/2013/01/Learning-Gravity-Forms.png" width="300" height="300" /></p>
<p>Looking for a great way to learn more about Gravity Forms? Perhaps you build sites and need a training resource for your clients to teach them how to use the plugin?</p>
<p>Well you&#8217;re mission on Google is over!</p>
<p>Published this week is a new eBook, <a title="How to guide for Gravity Forms" href="http://helpforwp.com/downloads/learning-gravity-forms-ebook/">Learning Gravity Forms</a>. Aimed at beginners who are using the WordPress plugin to build and manage forms on their website, the eBook is broken into two parts.</p>
<p><strong>Part I</strong> is a guided walk through that starts with setup of the plugin and then moves through the processes of building a &#8220;Contact us&#8221; form, including set up of notifications.</p>
<p><strong>Part II</strong> is then 6 recipes that will build on the basics, each recipe tackles a particular topic and cover the solution.</p>
<p>Check out more details over at <a title="Gravity Forms Training" href="http://helpforwp.com/downloads/learning-gravity-forms-ebook/">HelpForWP.com</a> where the eBook is available for $9 (Australian).</p>
<div class="shr-publisher-1725"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic --><img src="http://feeds.feedburner.com/~r/PeterShilling/~4/9rFPlrPwzsw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.shilling.id.au/2013/01/29/learning-gravity-forms-a-new-ebook/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.shilling.id.au/2013/01/29/learning-gravity-forms-a-new-ebook/</feedburner:origLink></item>
		<item>
		<title>Screen Capture Tool: full size capture of web page</title>
		<link>http://feedproxy.google.com/~r/PeterShilling/~3/yt_3iU4bYCk/</link>
		<comments>http://www.shilling.id.au/2013/01/20/screen-capture-tool-full-size-capture-of-web-page/#comments</comments>
		<pubDate>Sun, 20 Jan 2013 05:38:19 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[Everything else]]></category>

		<guid isPermaLink="false">http://www.shilling.id.au/?p=1649</guid>
		<description><![CDATA[I came across this simple, but brilliant tool this week. It does one thing but does it so well! It&#8217;s an online tool that allows you to enter a URL and it returns you a PNG file that is a screen capture of the full web site. Really useful if you&#8217;d like to send a [...]]]></description>
				<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:right;height:30px;'><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http://www.shilling.id.au/2013/01/20/screen-capture-tool-full-size-capture-of-web-page/' data-shr_title='Screen+Capture+Tool%3A+full+size+capture+of+web+page'></a><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http://www.shilling.id.au/2013/01/20/screen-capture-tool-full-size-capture-of-web-page/' data-shr_title='Screen+Capture+Tool%3A+full+size+capture+of+web+page'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetTop Automatic --><p>I came across this simple, but brilliant tool this week.</p>
<p>It does one thing but does it so well!</p>
<p>It&#8217;s an online tool that allows you to enter a URL and it returns you a PNG file that is a screen capture of the full web site. Really useful if you&#8217;d like to send a client a demo of a page etc. Previously I&#8217;ve had a couple of Mac apps that would do this, always love using an online tool that&#8217;s available anywhere.</p>
<p><img class="alignnone size-full wp-image-1651" alt="online.screen.shot" src="http://www.shilling.id.au/wp-content/uploads/2013/01/online.screen.shot_.png" width="500" height="153" /></p>
<p><a href="http://ctrlq.org/screenshots/" target="_blank">Check it out here.</p>
<p></a></p>
<div class="shr-publisher-1649"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic --><img src="http://feeds.feedburner.com/~r/PeterShilling/~4/yt_3iU4bYCk" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.shilling.id.au/2013/01/20/screen-capture-tool-full-size-capture-of-web-page/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.shilling.id.au/2013/01/20/screen-capture-tool-full-size-capture-of-web-page/</feedburner:origLink></item>
		<item>
		<title>WordPress child themes: how to find the path to the child theme</title>
		<link>http://feedproxy.google.com/~r/PeterShilling/~3/TnHsivFISws/</link>
		<comments>http://www.shilling.id.au/2012/11/15/wordpress-child-themes-how-to-find-the-path-to-the-child-theme/#comments</comments>
		<pubDate>Wed, 14 Nov 2012 21:46:05 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[WordPress Code]]></category>
		<category><![CDATA[child themes]]></category>
		<category><![CDATA[genesis]]></category>

		<guid isPermaLink="false">http://www.shilling.id.au/?p=1636</guid>
		<description><![CDATA[A quick snippet that shows you how to locate the path to your theme when you're using a WordPress child theme.]]></description>
				<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:right;height:30px;'><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http://www.shilling.id.au/2012/11/15/wordpress-child-themes-how-to-find-the-path-to-the-child-theme/' data-shr_title='WordPress+child+themes%3A+how+to+find+the+path+to+the+child+theme'></a><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http://www.shilling.id.au/2012/11/15/wordpress-child-themes-how-to-find-the-path-to-the-child-theme/' data-shr_title='WordPress+child+themes%3A+how+to+find+the+path+to+the+child+theme'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetTop Automatic --><p>Usually when you need to reference something inside your theme you can use this WordPress function</p>
<pre class="brush: php; title: ; notranslate">bloginfo('template_directory');</pre>
<p>Which works fine if you&#8217;re using a standard WordPress theme. However, if you are using a child theme or a framework like Genesis then the above will actually tell you where the parent theme is located, not the location of your child theme.</p>
<p>Try this instead.</p>
<pre class="brush: php; title: ; notranslate">$sample_image = dirname(get_bloginfo('stylesheet_url')) . &quot;/images/people-example.jpg&quot;;</pre>
<p>In this example, I want to access an image &#8220;people-example.jpg&#8221; that&#8217;s stored inside the child theme in a directory called &#8220;images&#8221;.</p>
<div class="shr-publisher-1636"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic --><img src="http://feeds.feedburner.com/~r/PeterShilling/~4/TnHsivFISws" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.shilling.id.au/2012/11/15/wordpress-child-themes-how-to-find-the-path-to-the-child-theme/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.shilling.id.au/2012/11/15/wordpress-child-themes-how-to-find-the-path-to-the-child-theme/</feedburner:origLink></item>
		<item>
		<title>WordPress custom post types, URLs and filtering</title>
		<link>http://feedproxy.google.com/~r/PeterShilling/~3/oaHxEJbe5UM/</link>
		<comments>http://www.shilling.id.au/2012/11/13/wordpress-custom-post-types-urls-and-filtering/#comments</comments>
		<pubDate>Tue, 13 Nov 2012 03:59:26 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[Wordpress Tips]]></category>
		<category><![CDATA[custom post types]]></category>

		<guid isPermaLink="false">http://www.shilling.id.au/?p=1634</guid>
		<description><![CDATA[Almost every WordPress site we build these days has at least one custom post type, some have more than a lot. I came across this post by Seth Stevenson that is a very good resource if you&#8217;re interested in how to use WordPress URLs to filter custom post types and their archive pages. It starts [...]]]></description>
				<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:right;height:30px;'><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http://www.shilling.id.au/2012/11/13/wordpress-custom-post-types-urls-and-filtering/' data-shr_title='WordPress+custom+post+types%2C+URLs+and+filtering'></a><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http://www.shilling.id.au/2012/11/13/wordpress-custom-post-types-urls-and-filtering/' data-shr_title='WordPress+custom+post+types%2C+URLs+and+filtering'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetTop Automatic --><p>Almost every WordPress site we build these days has at least one custom post type, some have more than a lot.</p>
<p>I came across <a href="http://sethstevenson.net/create-a-clean-url-for-your-custom-post-types-category-archives/" target="_blank">this post by Seth Stevenson</a> that is a very good resource if you&#8217;re interested in how to use WordPress URLs to filter custom post types and their archive pages.</p>
<p>It starts out showing you how to use URLs like</p>
<p>/category/portraits/?post_type=gallery</p>
<p>&#8230;to display &#8220;gallery&#8221; custom posts that may be in the category &#8220;portraits&#8221; but then goes on to show you how to re-write some of these urls to make clean URLs with less query string values.</p>
<p>Well worth adding to your bookmarks!</p>
<div class="shr-publisher-1634"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic --><img src="http://feeds.feedburner.com/~r/PeterShilling/~4/oaHxEJbe5UM" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.shilling.id.au/2012/11/13/wordpress-custom-post-types-urls-and-filtering/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.shilling.id.au/2012/11/13/wordpress-custom-post-types-urls-and-filtering/</feedburner:origLink></item>
		<item>
		<title>Genesis Framework: How to show excerpts or full content on archive pages</title>
		<link>http://feedproxy.google.com/~r/PeterShilling/~3/ODbkt_ueYTc/</link>
		<comments>http://www.shilling.id.au/2012/10/22/genesis-framework-how-to-show-experts-or-full-content-on-archive-pages/#comments</comments>
		<pubDate>Mon, 22 Oct 2012 04:56:24 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[WordPress Code]]></category>
		<category><![CDATA[genesis]]></category>

		<guid isPermaLink="false">http://www.shilling.id.au/?p=1213</guid>
		<description><![CDATA[When using Genesis, here's how to have one or more archive pages configured differently from the standard that is configured in the Genesis theme settings. ]]></description>
				<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:right;height:30px;'><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http://www.shilling.id.au/2012/10/22/genesis-framework-how-to-show-experts-or-full-content-on-archive-pages/' data-shr_title='Genesis+Framework%3A+How+to+show+excerpts+or+full+content+on+archive+pages'></a><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http://www.shilling.id.au/2012/10/22/genesis-framework-how-to-show-experts-or-full-content-on-archive-pages/' data-shr_title='Genesis+Framework%3A+How+to+show+excerpts+or+full+content+on+archive+pages'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetTop Automatic --><p>When using the Genesis theme framework you have the ability to control what is displayed on archive pages from the Genesis settings. This is particularly helpful if you have, in addition to standard pages and posts, one or more custom post types registered.</p>
<p>Check the screen shot below. The settings spell out your options.</p>
<p><img class="alignnone size-full wp-image-1214" title="control-archive-display" src="http://www.shilling.id.au/wp-content/uploads/2012/10/control-archive-display.png" alt="" width="642" height="273" /><br />
What happens though if you would like one or more archive pages to behave differently form the rest?<br />
Well the snippet of PHP code below will do the job!</p>
<pre class="brush: php; title: ; notranslate">
add_action( 'genesis_before', 'child_conditional_actions' );
function child_conditional_actions() {
    if( is_archive() &amp;&amp; 'post_type' == get_post_type() ) {
        //put your actions here
        remove_action( 'genesis_post_content', 'genesis_do_post_content' );
        remove_action( 'genesis_post_content', 'genesis_do_post_image' );
        add_action( 'genesis_post_content', 'the_content' );

    }

}
</pre>
<p>This line is the one that needs to be customised for your situation:</p>
<p>if( is_archive() &amp;&amp; &#8216;post_type&#8217; == get_post_type() ) {</p>
<p>&#8216;post_type&#8217; needs to be adjusted to be the custom post type that you would like to change, so for example if you have a custom post type movies you would have:</p>
<p>if( is_archive() &amp;&amp; &#8216;movies&#8217; == get_post_type() ) {</p>
<p>Thanks to Nick on the StudioPress.com forums for this snippet!</p>
<div class="shr-publisher-1213"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic --><img src="http://feeds.feedburner.com/~r/PeterShilling/~4/ODbkt_ueYTc" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.shilling.id.au/2012/10/22/genesis-framework-how-to-show-experts-or-full-content-on-archive-pages/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		<feedburner:origLink>http://www.shilling.id.au/2012/10/22/genesis-framework-how-to-show-experts-or-full-content-on-archive-pages/</feedburner:origLink></item>
		<item>
		<title>Genesis Framework: customise the post info by line</title>
		<link>http://feedproxy.google.com/~r/PeterShilling/~3/abF-9bwgRjw/</link>
		<comments>http://www.shilling.id.au/2012/10/22/genesis-framework-customise-the-post-info-by-line/#comments</comments>
		<pubDate>Sun, 21 Oct 2012 16:42:06 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[WordPress Code]]></category>
		<category><![CDATA[genesis]]></category>

		<guid isPermaLink="false">http://www.shilling.id.au/?p=1202</guid>
		<description><![CDATA[Here&#8217;s a little trick that allows you to customise the by line of posts, for both the archive pages and the single post. I was searching for a way to do this for a job where the requirement was to remove the author&#8217;s name but leave the post date and other info. What am I [...]]]></description>
				<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:right;height:30px;'><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http://www.shilling.id.au/2012/10/22/genesis-framework-customise-the-post-info-by-line/' data-shr_title='Genesis+Framework%3A+customise+the+post+info+by+line'></a><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http://www.shilling.id.au/2012/10/22/genesis-framework-customise-the-post-info-by-line/' data-shr_title='Genesis+Framework%3A+customise+the+post+info+by+line'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetTop Automatic --><p>Here&#8217;s a little trick that allows you to customise the by line of posts, for both the archive pages and the single post. I was searching for a way to do this for a job where the requirement was to remove the author&#8217;s name but leave the post date and other info.</p>
<p>What am I talking about? Here&#8217;s a screen shot of a customised Genesis theme, in this example the date and leave a comment remain but the author has been removed.</p>
<p><img class="alignnone size-full wp-image-1203" title="post-info" src="http://www.shilling.id.au/wp-content/uploads/2012/10/post-info.png" alt="customising post info section in Genesis" width="343" height="63" /></p>
<pre class="brush: php; title: ; notranslate">
/** Customize the post info function */
add_filter( 'genesis_post_info', 'post_info_filter' );

function post_info_filter($post_info) {
if (!is_page() ) {
 $post_info = '[ post_date] by [ post_author_posts_link] at [ post_time] [ post_comments] [ post_edit]';
 return $post_info;
}
}

</pre>
<p>Two key things here:</p>
<ul>
<li>Change the !is_page condition depending on what you&#8217;d like to effect, leave it like this to work on single posts and post archives</li>
<li>the line $post_info = &#8216;<span class="date published time" title="2012-10-22T03:42:06+00:00">October 22, 2012</span> &#8230;.. simply remove or add text as you need</li>
<li>[ post_date] etc.. are short codes, close up the gap at the start for them to work (bit of a hack to have them display here)
</ul>
<div class="shr-publisher-1202"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic --><img src="http://feeds.feedburner.com/~r/PeterShilling/~4/abF-9bwgRjw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.shilling.id.au/2012/10/22/genesis-framework-customise-the-post-info-by-line/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.shilling.id.au/2012/10/22/genesis-framework-customise-the-post-info-by-line/</feedburner:origLink></item>
		<item>
		<title>WordPress 404 and 301 redirects: the easy way</title>
		<link>http://feedproxy.google.com/~r/PeterShilling/~3/QZdMxZGjPfA/</link>
		<comments>http://www.shilling.id.au/2012/10/17/wordpress-404-redirect-and-301-redirect/#comments</comments>
		<pubDate>Wed, 17 Oct 2012 06:18:23 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[WordPress Plugin]]></category>
		<category><![CDATA[redirects]]></category>

		<guid isPermaLink="false">http://www.shilling.id.au/?p=1197</guid>
		<description><![CDATA[I came across a WordPress plugin this week, when trying to solve a problem for a client, that is simply brilliant. Here&#8217;s the situation. You&#8217;ve build a new WordPress website and when launching you realise that the old web site, regardless if it was WordPress or not has URLs to content that will not be [...]]]></description>
				<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><div class='shareaholic-like-buttonset' style='float:right;height:30px;'><a class='shareaholic-googleplusone' data-shr_size='medium' data-shr_count='true' data-shr_href='http://www.shilling.id.au/2012/10/17/wordpress-404-redirect-and-301-redirect/' data-shr_title='WordPress+404+and+301+redirects%3A+the+easy+way'></a><a class='shareaholic-fblike' data-shr_layout='button_count' data-shr_showfaces='false' data-shr_href='http://www.shilling.id.au/2012/10/17/wordpress-404-redirect-and-301-redirect/' data-shr_title='WordPress+404+and+301+redirects%3A+the+easy+way'></a></div><div style="clear: both; min-height: 1px; height: 3px; width: 100%;"></div><!-- End Shareaholic LikeButtonSetTop Automatic --><p>I came across a WordPress plugin this week, when trying to solve a problem for a client, that is simply brilliant. Here&#8217;s the situation. You&#8217;ve build a new WordPress website and when launching you realise that the old web site, regardless if it was WordPress or not has URLs to content that will not be the same on the new.</p>
<p>There is more than one way to solve this. Regularly what we do is get a complete list of the URLs from the old site and use .htaccess to redirect to the same content in the new website.</p>
<p>That&#8217;s fine and in some cases will still be the way that I approach the problem.</p>
<p>However, there&#8217;s a WordPress plugin &#8220;404 Redirected&#8221; that approaches the problem is a different way. Once installed and activated it will listen for 404 errors that are about to happen. It then will do some smarts to see if it can work out where the content is. For example if a post title in your new WordPress site matches the relevant part of the inbound URL &#8211; it will connect the two.</p>
<p>Since it has done the work once, the plugin will then create a 301 redirect so that the next time the WordPress setups has a request for that URL it will simply execute the redirect.</p>
<p>Obvious &#8211; yes, but I hadn&#8217;t thought of the approach the way it&#8217;s been put together is very nice.</p>
<div id="attachment_1198" class="wp-caption alignnone" style="width: 310px"><a href="http://www.shilling.id.au/wp-content/uploads/2012/10/404-redirect-screen-shot.png"><img class="size-medium wp-image-1198" title="404-redirect-screen-shot" src="http://www.shilling.id.au/wp-content/uploads/2012/10/404-redirect-screen-shot-300x69.png" alt="404-redirect-screen-shot" width="300" height="69" /></a><p class="wp-caption-text">Click to view stats screenshot larger</p></div>
<p>The plugin logs what it&#8217;s doing and even displays statistics like how many hits the redirected URL is receiving. There are some more detailed settings but on my first use I pretty much activated and used it as is, so the defaults are just fine to get you started.</p>
<p><img class="alignnone size-full wp-image-1199" title="404-redirect-settings" src="http://www.shilling.id.au/wp-content/uploads/2012/10/404-redirect-settings.png" alt="" width="562" height="318" /></p>
<p>Sound interesting? <a href="http://wordpress.org/extend/plugins/404-redirected/" target="_blank">Here is the plugin in the WordPress repository</a>.</p>
<div class="shr-publisher-1197"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic --><img src="http://feeds.feedburner.com/~r/PeterShilling/~4/QZdMxZGjPfA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.shilling.id.au/2012/10/17/wordpress-404-redirect-and-301-redirect/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.shilling.id.au/2012/10/17/wordpress-404-redirect-and-301-redirect/</feedburner:origLink></item>
	</channel>
</rss>
