<?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/"
	>

<channel>
	<title>Frankie Jarrett</title>
	<atom:link href="http://frankiejarrett.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://frankiejarrett.com</link>
	<description>WordPress developer. Web geek. Jesus freak.</description>
	<lastBuildDate>Wed, 16 May 2012 15:31:01 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>How to hide your WordPress version number&#8230;completely</title>
		<link>http://frankiejarrett.com/2012/05/how-to-hide-your-wordpress-version-number-completely/</link>
		<comments>http://frankiejarrett.com/2012/05/how-to-hide-your-wordpress-version-number-completely/#comments</comments>
		<pubDate>Thu, 10 May 2012 23:41:48 +0000</pubDate>
		<dc:creator>Frankie Jarrett</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[custom functions]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[tricks]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://frankiejarrett.com/?p=231</guid>
		<description><![CDATA[Did you know that your WordPress version number is visible to everyone? As Matt Mullenweg rightly pointed out several years ago, simply hiding your WordPress version number is not enough by itself to stay protected from potential threats (you should &#8230; <a href="http://frankiejarrett.com/2012/05/how-to-hide-your-wordpress-version-number-completely/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Did you know that your WordPress version number is visible to everyone?</p>
<p>As Matt Mullenweg rightly pointed out several years ago, simply hiding your WordPress version number is <a href="http://wordpress.org/news/2009/09/keep-wordpress-secure/" title="How to Keep WordPress Secure" target="_blank">not enough</a> by itself to stay protected from potential threats (you should <em>always</em> be keeping your WordPress installation up-to-date).</p>
<p>But perhaps you have a client who has specifically requested its removal or maybe you just like keeping things on the safe side, either way there are a lot of tutorials out there on how to remove it from various areas but none that I&#8217;ve found showing how to remove it from <em>every area at the same time</em>.</p>
<p>The WordPress version number appears in three areas:</p>
<h2>1. Generator Meta Tag in the Header</h2>
<p><code>&lt;meta name="generator" content="WordPress 3.3.2" /&gt;</code></p>
<h2>2. Generator Tag in RSS Feeds</h2>
<p><code>&lt;generator&gt;http://wordpress.org/?v=3.3.2&lt;/generator&gt;</code></p>
<h2>3. Query Strings on Scripts &amp; Styles</h2>
<p>If a script or style does not specify a version number when enqueued, the current version of WordPress is used.</p>
<p><code>foo.js?ver=3.3.2</code></p>
<h2>One Block of Code to Rule Them All</h2>
<p>Just enter this into your <code>functions.php</code> file and your WordPress version will be safely hidden from the public.</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
&nbsp;
<span style="color: #666666; font-style: italic;">/* Hide WP version meta tag from header and generator tag from feeds
 * @return null
 * @filter the_generator
 */</span>
<span style="color: #000000; font-weight: bold;">function</span> fjarrett_remove_wp_version_tag<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">null</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
add_filter<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'the_generator'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'fjarrett_remove_wp_version_tag'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">/* Hide WP version strings from scripts and styles
 * @return {string} $src
 * @filter script_loader_src
 * @filter style_loader_src
 */</span>
<span style="color: #000000; font-weight: bold;">function</span> fjarrett_remove_wp_version_strings<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$src</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$wp_version</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000088;">$parts</span> <span style="color: #339933;">=</span> <span style="color: #990000;">explode</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'?'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$src</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$parts</span><span style="color: #009900;">&#91;</span><span style="color: #cc66cc;">1</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">===</span> <span style="color: #0000ff;">'ver='</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$wp_version</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">return</span> <span style="color: #000088;">$parts</span><span style="color: #009900;">&#91;</span><span style="color: #cc66cc;">0</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">return</span> <span style="color: #000088;">$src</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span>
add_filter<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'script_loader_src'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'fjarrett_remove_wp_version_strings'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
add_filter<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'style_loader_src'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'fjarrett_remove_wp_version_strings'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

<p><a href="https://gist.github.com/2657482" title="How to hide your WordPress version number…completely" target="_blank"><img src="http://frankiejarrett.com/wp-content/uploads/2012/05/fork-me-on-github-e1336710192114-150x23.png" alt="Fork me on GitHub" title="Fork me on GitHub" width="150" height="23" /></a></p>
<p>However, there is one small caveat to be aware of when using this method: This function will check to see if the <code>ver</code> query string matches the WordPress version number, so if the version of the enqueued script happens to be the exact same as the WordPress version then its version string will be removed as well.</p>
<p>This will occur rarely (if ever), especially when the current WordPress version is a point release, such as 3.3.2.</p>
]]></content:encoded>
			<wfw:commentRss>http://frankiejarrett.com/2012/05/how-to-hide-your-wordpress-version-number-completely/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>I&#8217;ve been HEROized as The Solution!</title>
		<link>http://frankiejarrett.com/2012/04/ive-been-heroized-as-the-solution/</link>
		<comments>http://frankiejarrett.com/2012/04/ive-been-heroized-as-the-solution/#comments</comments>
		<pubDate>Sat, 28 Apr 2012 02:12:57 +0000</pubDate>
		<dc:creator>Frankie Jarrett</dc:creator>
				<category><![CDATA[Thoughts]]></category>
		<category><![CDATA[heroized]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[x-team]]></category>

		<guid isPermaLink="false">http://frankiejarrett.com/?p=371</guid>
		<description><![CDATA[Last night was a very memorable night for me as my friends at X-Team unveiled my inner superhero, dubbing me as The Solution! The Solution When Frankie Jarrett isn&#8217;t living his passion for working in WordPress or making music, he&#8217;s &#8230; <a href="http://frankiejarrett.com/2012/04/ive-been-heroized-as-the-solution/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Last night was a very memorable night for me as my friends at <a href="http://x-team.com" target="_blank">X-Team</a> unveiled my inner superhero, dubbing me as <em>The Solution!</em></p>
<p><img class="aligncenter size-full wp-image-372" title="Frankie Jarrett - The Solution" src="http://frankiejarrett.com/wp-content/uploads/2012/04/Frankie-Jarrett-The-Solution.jpg" alt="" width="330" height="330" /></p>
<blockquote><p><strong>The Solution</strong></p>
<p><strong></strong>When Frankie Jarrett isn&#8217;t living his passion for working in WordPress or making music, he&#8217;s the problem solving hero known as, The Solution!</p>
<p>He was born with the amazing cerebral super power to solve any problem. Frankie can always figure out a way to communicate clearly with anyone. He is often there to listen and offer support to others, no matter how difficult their situation. Often Frankie only needs to say, &#8220;I&#8217;ll have to think about this problem a little&#8221;, and soon he has an exciting solution!</p>
<p>No situation is too big or too small and there is no danger too great for him to face. Whether you are having a tough time remembering trigonometry for your math test, or you are stranded on the roof of a burning building, The Solution can always figure out the best way to rescue someone.</p>
<p>Our hero also has the natural ability to inspire others, whether leading musical worship in his church or jamming with friends, Frankie uses his voice and musical talents to uplift and inspire those around him.</p>
<p>When not saving the innocent, Frankie spends his time watching the History channel with his wife, whom he absolutely adores.</p></blockquote>
<p>Being <a href="http://heroized.com" target="_blank">HEROized</a> is a true honor, and I am grateful to <a title="Follow Dave Rosen" href="http://twitter.com/ft5" target="_blank">Dave</a> and the rest of the team for recognizing me in this way.</p>
<p>Now to create more solutions! <img src='http://frankiejarrett.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://frankiejarrett.com/2012/04/ive-been-heroized-as-the-solution/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Add first and last classes to your loop without using JavaScript</title>
		<link>http://frankiejarrett.com/2012/04/add-first-and-last-classes-to-your-loop-without-using-javascript/</link>
		<comments>http://frankiejarrett.com/2012/04/add-first-and-last-classes-to-your-loop-without-using-javascript/#comments</comments>
		<pubDate>Sun, 15 Apr 2012 22:36:34 +0000</pubDate>
		<dc:creator>Frankie Jarrett</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[custom functions]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[loop]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://frankiejarrett.com/?p=236</guid>
		<description><![CDATA[So you&#8217;re a pixel-perfect designer who wants to keep control over your WordPress loop styles? Hell yeah! You&#8217;re already pretty cool in my book. You&#8217;ve probably got a fancy post separator, or a brilliant doodle to fit between your last &#8230; <a href="http://frankiejarrett.com/2012/04/add-first-and-last-classes-to-your-loop-without-using-javascript/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>So you&#8217;re a pixel-perfect designer who wants to keep control over your WordPress loop styles? Hell yeah! You&#8217;re already pretty cool in my book.</p>
<p>You&#8217;ve probably got a fancy post separator, or a brilliant doodle to fit between your last post and the comments. Whatever the reason, you don&#8217;t have CSS class selectors for targeting the first or last posts in your archive &#8211; and you really need them.</p>
<p>There are a lot of tutorials on how to achieve this with jQuery. But it&#8217;s not worth relying on JavaScript for something that can easily be done with a little PHP magic.</p>
<p>First, insert this function into your <code>functions.php</code> file.</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #009933; font-style: italic;">/**
 * Display the classes for the post div and automatically mark the first and last posts
 * 
 * @param {string|array} $class - One or more classes separated by spaces
 * @param {int} $post_id - An optional post ID
 */</span>
<span style="color: #000000; font-weight: bold;">function</span> fjarrett_post_class<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$class</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">''</span><span style="color: #339933;">,</span> <span style="color: #000088;">$post_id</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">null</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$wp_query</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$class</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$class</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">' '</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$wp_query</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">current_post</span> <span style="color: #339933;">===</span> <span style="color: #cc66cc;">0</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$class</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">'first'</span><span style="color: #339933;">;</span>
		<span style="color: #b1b100;">return</span> post_class<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$class</span><span style="color: #339933;">,</span> <span style="color: #000088;">$post_id</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #b1b100;">elseif</span> <span style="color: #009900;">&#40;</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$wp_query</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">current_post</span> <span style="color: #339933;">+</span> <span style="color: #cc66cc;">1</span> <span style="color: #009900;">&#41;</span> <span style="color: #339933;">===</span> <span style="color: #000088;">$wp_query</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">post_count</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$class</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">'last'</span><span style="color: #339933;">;</span>
		<span style="color: #b1b100;">return</span> post_class<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$class</span><span style="color: #339933;">,</span> <span style="color: #000088;">$post_id</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">return</span> post_class<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$class</span><span style="color: #339933;">,</span> <span style="color: #000088;">$post_id</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>Now, open up <code>loop.php</code> and replace <code>post_class()</code> with the newly created <code>fjarrett_post_class()</code>.</p>
<p>This new function accepts the same parameters as the <a href="http://codex.wordpress.org/Function_Reference/post_class" title="Function Reference/post class" target="_blank">original function</a>, so you can use it the exact same way. The only difference will be that the first and last posts will be marked automatically with an appropriate class name. Enjoy total control. <img src='http://frankiejarrett.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>If this helped you in any way I&#8217;d love to hear about it in the comments!</p>
]]></content:encoded>
			<wfw:commentRss>http://frankiejarrett.com/2012/04/add-first-and-last-classes-to-your-loop-without-using-javascript/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The simplest way to require/include wp-load.php</title>
		<link>http://frankiejarrett.com/2012/04/the-simplest-way-to-require-include-wp-load-php/</link>
		<comments>http://frankiejarrett.com/2012/04/the-simplest-way-to-require-include-wp-load-php/#comments</comments>
		<pubDate>Fri, 06 Apr 2012 22:23:43 +0000</pubDate>
		<dc:creator>Frankie Jarrett</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[hacks]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[tricks]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://frankiejarrett.com/?p=227</guid>
		<description><![CDATA[If you want to use WordPress functionality in a PHP file that exists outside of your WordPress installation then you need to include wp-load.php. Perhaps you could call this &#8220;hooking into WordPress&#8221;. Maybe you&#8217;re already using some sort of relative &#8230; <a href="http://frankiejarrett.com/2012/04/the-simplest-way-to-require-include-wp-load-php/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>If you want to use WordPress functionality in a PHP file that exists outside of your WordPress installation then you need to include <code>wp-load.php</code>. Perhaps you could call this &#8220;hooking into WordPress&#8221;.</p>
<p>Maybe you&#8217;re already using some sort of relative path method, like:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">include</span> <span style="color: #0000ff;">'../../../wp-load.php'</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>But this can create problems if directories change. You need a clean, dynamic way to get <code>wp-load.php</code>. So here is the simplest way to do it, with just two lines of code (place it at the very top of your file):</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
&nbsp;
<span style="color: #000088;">$parse_uri</span> <span style="color: #339933;">=</span> <span style="color: #990000;">explode</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'wp-content'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$_SERVER</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'SCRIPT_FILENAME'</span><span style="color: #009900;">&#93;</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">require_once</span><span style="color: #009900;">&#40;</span> <span style="color: #000088;">$parse_uri</span><span style="color: #009900;">&#91;</span><span style="color: #cc66cc;">0</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'wp-load.php'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

<p>Short and sweet <img src='http://frankiejarrett.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><span style="color: #ff0000;">Disclaimer:</span> This is intended for experimental and development purposes only. It is not advised to redundantly load WordPress on live production environments. <a href="http://ottopress.com/2010/dont-include-wp-load-please/" target="_blank">But, why?</a></p>
]]></content:encoded>
			<wfw:commentRss>http://frankiejarrett.com/2012/04/the-simplest-way-to-require-include-wp-load-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Joining X-Team</title>
		<link>http://frankiejarrett.com/2011/10/joining-x-team/</link>
		<comments>http://frankiejarrett.com/2011/10/joining-x-team/#comments</comments>
		<pubDate>Fri, 28 Oct 2011 06:02:02 +0000</pubDate>
		<dc:creator>Frankie Jarrett</dc:creator>
				<category><![CDATA[Thoughts]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[x-team]]></category>

		<guid isPermaLink="false">http://frankiejarrett.com/?p=215</guid>
		<description><![CDATA[Not long ago I was contacted by Dave Rosen, the CEO of X-Team, who had stumbled across my blog (this one). He was looking for a WordPress guru who could help wrangle up their many projects on the technical/development side &#8230; <a href="http://frankiejarrett.com/2011/10/joining-x-team/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Not long ago I was contacted by Dave Rosen, the CEO of <a href="http://x-team.com" target="_blank">X-Team</a>, who had stumbled across my blog (this one). He was looking for a WordPress guru who could help wrangle up their many projects on the technical/development side of things.</p>
<p>After just three days of communicating back and forth (and one Skype call) he offered me a full-time position, and I wholeheartedly accepted! He flew me to Los Angeles a few days later to sync up with his top developers, Weston and Josh, who have been temporarily living here while working at FOX Broadcasting.</p>
<p>Needless to say, it&#8217;s been an outstanding experience working with these two. They&#8217;re not only top notch programmers but also great guys who are a blast to hang out with and have become good friends of mine. Since I&#8217;ve been here I&#8217;ve really enjoyed soaking up all the new information and techniques X-Team uses, specifically learning to incorporate version control with <a href="http://git-scm.com/" target="_blank">Git</a> via command line into my workflow. I&#8217;m very happy to say I&#8217;m no longer <a href="http://2011.sf.wordcamp.org/session/scaling-servers-and-deploys-oh-my/" target="_blank">Cowboy Coding</a>! <img src='http://frankiejarrett.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>My next big task (apart from client projects) is to bring a WordPress framework into fruition for X-Team that we&#8217;re calling: WPized. <a href="http://weston.ruter.net" target="_blank">Weston Ruter</a> has laid a ton of groundwork for the WPized framework already, so I&#8217;ll be taking a lot of what he&#8217;s started and simplifying it into a tool for creating themes rapidly. I&#8217;ll also be writing a lot of documentation for our other WP developers so they will know how to use the custom helper functions the framework will offer and all of this will hopefully make the process of theming much more unified within X-Team.</p>
<p>It&#8217;s an extreme privilege to be doing what I love for a company that boasts some very big clients, has a long history of doing extraordinary things and has a lot of fun doing it! I am very fortunate to not only be running my own <a title="WordPress Church Themes" href="http://churchthemes.net" target="_blank">theme shop</a> but now also working with a superb international team on WordPress projects full-time&#8230;from home!</p>
]]></content:encoded>
			<wfw:commentRss>http://frankiejarrett.com/2011/10/joining-x-team/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Create a dropdown of custom taxonomies in WordPress (the easy way)</title>
		<link>http://frankiejarrett.com/2011/09/create-a-dropdown-of-custom-taxonomies-in-wordpress-the-easy-way/</link>
		<comments>http://frankiejarrett.com/2011/09/create-a-dropdown-of-custom-taxonomies-in-wordpress-the-easy-way/#comments</comments>
		<pubDate>Fri, 02 Sep 2011 20:05:26 +0000</pubDate>
		<dc:creator>Frankie Jarrett</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[custom functions]]></category>
		<category><![CDATA[custom taxonomies]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://frankiejarrett.com/?p=161</guid>
		<description><![CDATA[So you&#8217;ve been busy taking advantage of custom post type functionalities in WordPress since mid 2010. And of course you&#8217;re using custom taxonomies too, right? Of course you are. If you&#8217;re a theme or plugin developer you may have ran across &#8230; <a href="http://frankiejarrett.com/2011/09/create-a-dropdown-of-custom-taxonomies-in-wordpress-the-easy-way/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>So you&#8217;ve been busy taking advantage of <a href="http://codex.wordpress.org/Post_Types#Custom_Types" target="_blank">custom post type</a> functionalities in WordPress since mid 2010. And of course you&#8217;re using <a href="http://codex.wordpress.org/Taxonomies#Custom_Taxonomies" target="_blank">custom taxonomies</a> too, right? Of course you are.</p>
<p>If you&#8217;re a theme or plugin developer you may have ran across the need to populate a dropdown list of your custom taxonomies. Essentially there are two different (easy) ways to accomplish this. One you always hear about and the other you don&#8217;t.</p>
<h2>Method #1</h2>
<p>Since WP 2.1 the <code><a href="http://codex.wordpress.org/Function_Reference/wp_dropdown_categories" target="_blank">wp_dropdown_categories</a></code> function has been around but in WP 3.0 the <code>taxonomy</code> argument was introduced. So just calling this function and using the <code>taxonomy</code> argument is probably the absolute easiest way to populate a dropdown list of your custom taxonomies.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span> wp_dropdown_categories<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'taxonomy=my_custom_taxonomy'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>This method is great if you need the output of your dropdown values to be the category ID. Because this is the HTML that will be generated:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
</pre></td><td class="code"><pre class="html" style="font-family:monospace;">&lt;select name=&quot;cat&quot; class=&quot;postform&quot;&gt;
	&lt;option value=&quot;3&quot;&gt;Tax A&lt;/option&gt;
	&lt;option value=&quot;14&quot;&gt;Tax B&lt;/option&gt;
	&lt;option value=&quot;26&quot;&gt;Tax C&lt;/option&gt;
	&lt;option value=&quot;29&quot;&gt;Tax D&lt;/option&gt;
&lt;/select&gt;</pre></td></tr></table></div>

<p>However, let&#8217;s say you want your option value output to be the taxonomy&#8217;s slug instead of the ID. Well, that&#8217;s impossible to achieve using the <code>wp_dropdown_categories</code> function.</p>
<p>Peering into the WordPress core we see that this function is using a walker class called <code>Walker_CategoryDropdown</code>. This walker is designed to output only the ID as the value for each dropdown item. There is not an argument in the function to control value output.</p>
<h2>Method #2</h2>
<p>That&#8217;s where Method #2 comes in. We&#8217;ll have to write our own custom function that will generate the dropdown so we can output each option value as a slug:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">function</span> fjarrett_custom_taxonomy_dropdown<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$taxonomy</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000088;">$terms</span> <span style="color: #339933;">=</span> get_terms<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$taxonomy</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$terms</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #990000;">printf</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'&lt;select name=&quot;%s&quot; class=&quot;postform&quot;&gt;'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$taxonomy</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #b1b100;">foreach</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$terms</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$term</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
			<span style="color: #990000;">printf</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'&lt;option value=&quot;%s&quot;&gt;%s&lt;/option&gt;'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$term</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">slug</span><span style="color: #339933;">,</span> <span style="color: #000088;">$term</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">name</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</span>
		<span style="color: #b1b100;">print</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'&lt;/select&gt;'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>So, now that we&#8217;ve got a cool custom function, we can call anywhere in our code like so:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span> fjarrett_custom_taxonomy_dropdown<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'my_custom_taxonomy'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<h2>Expansions on Method #2</h2>
<p>If you&#8217;re a coding rockstar you can take Method #2 even further by making room for more parameters. This will give you even more control and make it function more like <code>wp_dropdown_categories</code> does:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">function</span> fjarrett_custom_taxonomy_dropdown<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$taxonomy</span><span style="color: #339933;">,</span> <span style="color: #000088;">$orderby</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'date'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$order</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'DESC'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$limit</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'-1'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$name</span><span style="color: #339933;">,</span> <span style="color: #000088;">$show_option_all</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">null</span><span style="color: #339933;">,</span> <span style="color: #000088;">$show_option_none</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">null</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000088;">$args</span> <span style="color: #339933;">=</span> <span style="color: #990000;">array</span><span style="color: #009900;">&#40;</span>
		<span style="color: #0000ff;">'orderby'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$orderby</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'order'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$order</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'number'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$limit</span><span style="color: #339933;">,</span>
	<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$terms</span> <span style="color: #339933;">=</span> get_terms<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$taxonomy</span><span style="color: #339933;">,</span> <span style="color: #000088;">$args</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$name</span> <span style="color: #339933;">=</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$name</span> <span style="color: #009900;">&#41;</span> ? <span style="color: #000088;">$name</span> <span style="color: #339933;">:</span> <span style="color: #000088;">$taxonomy</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$terms</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #990000;">printf</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'&lt;select name=&quot;%s&quot; class=&quot;postform&quot;&gt;'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$name</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$show_option_all</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
			<span style="color: #990000;">printf</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'&lt;option value=&quot;0&quot;&gt;%s&lt;/option&gt;'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$show_option_all</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</span>
		<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$show_option_none</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
			<span style="color: #990000;">printf</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'&lt;option value=&quot;-1&quot;&gt;%s&lt;/option&gt;'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$show_option_none</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</span>
		<span style="color: #b1b100;">foreach</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$terms</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$term</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
			<span style="color: #990000;">printf</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'&lt;option value=&quot;%s&quot;&gt;%s&lt;/option&gt;'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$term</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">slug</span><span style="color: #339933;">,</span> <span style="color: #000088;">$term</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">name</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</span>
		<span style="color: #b1b100;">print</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'&lt;/select&gt;'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>Then call it in your code like so:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span> fjarrett_custom_taxonomy_dropdown<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'my_custom_taxonomy'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'date'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'DESC'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'5'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'my_custom_taxonomy'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'Select All'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'Select None'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<h2>Conclusion</h2>
<p>As you can see, WordPress has done a fabulous job of making room for you and I to do pretty much whatever we want.</p>
<p>To reference all available arguments and parameters, please see:<br />
<a href="http://codex.wordpress.org/Function_Reference/wp_dropdown_categories" target="_blank">http://codex.wordpress.org/Function_Reference/wp_dropdown_categories</a><br />
<a href="http://codex.wordpress.org/Function_Reference/get_terms" target="_blank">http://codex.wordpress.org/Function_Reference/get_terms</a></p>
<p>Was this code helpful to you? Let me know in the comments!</p>
]]></content:encoded>
			<wfw:commentRss>http://frankiejarrett.com/2011/09/create-a-dropdown-of-custom-taxonomies-in-wordpress-the-easy-way/feed/</wfw:commentRss>
		<slash:comments>15</slash:comments>
		</item>
		<item>
		<title>How to remove an auto-complete URL from Chrome on a Mac</title>
		<link>http://frankiejarrett.com/2011/08/how-to-remove-an-auto-complete-url-from-chrome-on-a-mac/</link>
		<comments>http://frankiejarrett.com/2011/08/how-to-remove-an-auto-complete-url-from-chrome-on-a-mac/#comments</comments>
		<pubDate>Tue, 23 Aug 2011 17:54:48 +0000</pubDate>
		<dc:creator>Frankie Jarrett</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[chrome]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[webkit]]></category>

		<guid isPermaLink="false">http://frankiejarrett.com/?p=129</guid>
		<description><![CDATA[If you&#8217;re at all like me, you get very annoyed at little things The Scenario Let&#8217;s imagine you love to browse with Chrome on your beloved Mac and you frequently visit Facebook. So you type the letters fa in your browser&#8217;s &#8230; <a href="http://frankiejarrett.com/2011/08/how-to-remove-an-auto-complete-url-from-chrome-on-a-mac/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;re at all like me, you get very annoyed at little things <img src='http://frankiejarrett.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<h2>The Scenario</h2>
<p>Let&#8217;s imagine you love to browse with <a href="http://www.google.com/chrome" target="_blank">Chrome</a> on your beloved Mac and you frequently visit Facebook. So you type the letters <code>fa</code> in your browser&#8217;s address bar and *bam!* the URL auto-completes to read <code>facebook.com</code>.</p>
<p>It truly is a wonderful thing. But sometimes, it&#8217;s not so wonderful.</p>
<h2>The Problem</h2>
<p><a href="http://www.google.com/support/forum/p/Chrome/thread?tid=075a627e7d92e38c" target="_blank">Some users are reporting</a> that when you first startup Safari or Chrome on a Mac the browser may take a while to load those auto-complete gems from your history. That&#8217;s not good when you&#8217;re used to typing <code>fa</code> and rapidly pressing <code>Enter</code>.</p>
<p>Oops! Now you&#8217;ve just asked your browser to visit <code>fa</code> (which does not exist) and from this point on <code>facebook.com</code> will show up as the second auto-complete option. Yikes! How do we remove that darn <code>fa</code> entry now showing above the actual entry we want?</p>
<p>There is hope.</p>
<h2>The Solution</h2>
<p>On a PC everyone seems to have the answer. You simply highlight the entry and press <strong>Shift + Delete</strong>. But us Mac users have an extra step that no one seems to be talking about.</p>
<p>On a Mac, you need to highlight the entry and then press <strong>Fn + Shift + Del</strong>. Now, you might need to wait a bit, or restart the browser to see it removed but I found it to work perfectly.</p>
<p>Did this work for you? Let me know in the comments.</p>
]]></content:encoded>
			<wfw:commentRss>http://frankiejarrett.com/2011/08/how-to-remove-an-auto-complete-url-from-chrome-on-a-mac/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>5 Cross-platform mobile frameworks worth considering</title>
		<link>http://frankiejarrett.com/2011/08/5-cross-platform-mobile-frameworks-worth-considering/</link>
		<comments>http://frankiejarrett.com/2011/08/5-cross-platform-mobile-frameworks-worth-considering/#comments</comments>
		<pubDate>Fri, 19 Aug 2011 02:38:51 +0000</pubDate>
		<dc:creator>Frankie Jarrett</dc:creator>
				<category><![CDATA[Reviews]]></category>
		<category><![CDATA[android]]></category>
		<category><![CDATA[css3]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[ios]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[mobile]]></category>

		<guid isPermaLink="false">http://frankiejarrett.com/?p=113</guid>
		<description><![CDATA[I&#8217;ve been doing a shallow dive into the development of native mobile apps. In my exploring, I&#8217;ve discovered a lot of conversation about these five mobile frameworks that seem to be speeding up development time and productivity: Titanium PhoneGap Rhomobile &#8230; <a href="http://frankiejarrett.com/2011/08/5-cross-platform-mobile-frameworks-worth-considering/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been doing a shallow dive into the development of native mobile apps. In my exploring, I&#8217;ve discovered a lot of conversation about these five mobile frameworks that seem to be speeding up development time and productivity:</p>
<p><a href="http://www.appcelerator.com/products/titanium-mobile-application-development/" target="_blank">Titanium</a><br />
<a href="http://www.phonegap.com/" target="_blank"> PhoneGap</a><br />
<a href="http://rhomobile.com/"> Rhomobile</a><br />
<a href="http://www.anscamobile.com/corona/" target="_blank"> Corona</a><br />
<a href="http://www.sencha.com/products/touch/" target="_blank"> Sencha Touch</a></p>
<p>Has anyone had any experience with one or more of these?</p>
]]></content:encoded>
			<wfw:commentRss>http://frankiejarrett.com/2011/08/5-cross-platform-mobile-frameworks-worth-considering/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Create a shortcode for displaying Order History on your Cart66 site</title>
		<link>http://frankiejarrett.com/2011/08/create-a-shortcode-for-displaying-order-history-on-your-cart66-site/</link>
		<comments>http://frankiejarrett.com/2011/08/create-a-shortcode-for-displaying-order-history-on-your-cart66-site/#comments</comments>
		<pubDate>Mon, 15 Aug 2011 00:21:47 +0000</pubDate>
		<dc:creator>Frankie Jarrett</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[cart66]]></category>
		<category><![CDATA[custom functions]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[shortcodes]]></category>

		<guid isPermaLink="false">http://frankiejarrett.com/?p=38</guid>
		<description><![CDATA[I&#8217;m a fan of Cart66. It&#8217;s easy to integrate and has a fair amount of features that make it a flexible e-commerce and member management solution for WordPress. However, there&#8217;s one pretty big feature that Cart66 is missing: the ability &#8230; <a href="http://frankiejarrett.com/2011/08/create-a-shortcode-for-displaying-order-history-on-your-cart66-site/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m a fan of <a href="http://cart66.com/" target="_blank">Cart66</a>. It&#8217;s easy to integrate and has a fair amount of features that make it a flexible e-commerce and member management solution for WordPress.</p>
<p>However, there&#8217;s one pretty big feature that Cart66 is missing: the ability to display the Order History of a logged in user.</p>
<p>What? Really?</p>
<p>Yes. Really.</p>
<p>This doesn&#8217;t really require a lot of explanation. It was easy to achieve with a simple SQL query and a custom loop. And all without editing the Cart66 core! So you can keep updating the plugin without worry. <img src='http://frankiejarrett.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Websites that sell digital goods will especially find this handy since users will be able to view their past receipts to re-download purchases.</p>
<p>Just insert this code into the functions.php file of your WordPress theme and use the shortcode <code>[order_history]</code> on a member&#8217;s only page to show the Order History for that user. Enjoy!</p>
<p>The original code for this idea came from a post by <a title="Show a user’s order history on “My Account” in Cart66" href="http://alisothegeek.com/2011/06/show-a-users-order-history-on-my-account-in-cart66/" target="_blank">Alison Barrett</a>.</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">/* Shortcode for displaying Cart66 order history for the current logged in user
 *
 * @return {string} $table
 * @shortcode order_history
 */</span>
<span style="color: #000000; font-weight: bold;">function</span> cart66_order_history<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$atts</span><span style="color: #339933;">,</span> <span style="color: #000088;">$content</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">null</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #990000;">extract</span><span style="color: #009900;">&#40;</span> shortcode_atts<span style="color: #009900;">&#40;</span> <span style="color: #990000;">array</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> <span style="color: #000088;">$atts</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$wpdb</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$results</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$wpdb</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">get_results</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">&quot;SELECT ouid, ordered_on, trans_id, total, status FROM &quot;</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$wpdb</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">prefix</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">&quot;cart66_orders WHERE account_id = &quot;</span> <span style="color: #339933;">.</span> Cart66Session<span style="color: #339933;">::</span><span style="color: #004000;">get</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'Cart66AccountId'</span> <span style="color: #009900;">&#41;</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">' ORDER BY ordered_on DESC'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">foreach</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$results</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$order</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$data</span> <span style="color: #339933;">.=</span> <span style="color: #990000;">sprintf</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'&lt;tr&gt;&lt;td&gt;%s&lt;/td&gt;&lt;td&gt;%s&lt;/td&gt;&lt;td&gt;%s&lt;/td&gt;&lt;td&gt;%s&lt;/td&gt;&lt;td&gt;&lt;a href=&quot;%s&quot; title=&quot;%s&quot; target=&quot;_blank&quot;&gt;%s&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$order</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">trans_id</span><span style="color: #339933;">,</span> <span style="color: #990000;">date</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'F j, Y'</span><span style="color: #339933;">,</span> <span style="color: #990000;">strtotime</span><span style="color: #009900;">&#40;</span> <span style="color: #000088;">$order</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">ordered_on</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> <span style="color: #000088;">$order</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">total</span><span style="color: #339933;">,</span> <span style="color: #990000;">ucwords</span><span style="color: #009900;">&#40;</span> <span style="color: #000088;">$order</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">status</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> home_url<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'/store/receipt/?ouid='</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$order</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">ouid</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> __<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'Click to view receipt'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'cart66'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> __<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'View Receipt'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'cart66'</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #000088;">$table</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'&lt;table id=&quot;viewCartTable&quot;&gt;
				&lt;thead&gt;
					&lt;tr&gt;
						&lt;th&gt;Order Number&lt;/th&gt;
						&lt;th&gt;Date&lt;/th&gt;
						&lt;th&gt;Total&lt;/th&gt;
						&lt;th&gt;Order Status&lt;/th&gt;
						&lt;th&gt;Receipt&lt;/th&gt;
					&lt;/tr&gt;
				&lt;/thead&gt;
				&lt;tbody&gt;'</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$data</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'&lt;/tbody&gt;&lt;/table&gt;'</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #000088;">$table</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
add_shortcode<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'order_history'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'cart66_order_history'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://frankiejarrett.com/2011/08/create-a-shortcode-for-displaying-order-history-on-your-cart66-site/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>What&#8217;s the future of the WordPress iOS app?</title>
		<link>http://frankiejarrett.com/2011/08/whats-the-future-of-the-wordpress-ios-app/</link>
		<comments>http://frankiejarrett.com/2011/08/whats-the-future-of-the-wordpress-ios-app/#comments</comments>
		<pubDate>Thu, 11 Aug 2011 00:13:55 +0000</pubDate>
		<dc:creator>Frankie Jarrett</dc:creator>
				<category><![CDATA[Thoughts]]></category>
		<category><![CDATA[ios]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://frankiejarrett.com/?p=31</guid>
		<description><![CDATA[I don&#8217;t launch the WordPress iOS application very often, and when I do it&#8217;s usually to do a quick typo fix on a post, page or comment. Sadly, there is no other reason to use it. Once, I heard Matt &#8230; <a href="http://frankiejarrett.com/2011/08/whats-the-future-of-the-wordpress-ios-app/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I don&#8217;t launch the WordPress iOS application very often, and when I do it&#8217;s usually to do a quick typo fix on a post, page or comment. Sadly, there is no other reason to use it.</p>
<p>Once, I heard <a href="http://ma.tt" target="_blank">Matt Mullenweg</a> mention in a podcast interview (can&#8217;t remember where, sorry) that he really wasn&#8217;t happy with the app and agreed there was still a lot to be done. I&#8217;m always glad to see Matt pushing for more and it makes me very optimistic about the app&#8217;s future.</p>
<p>I don&#8217;t intend for this post to be a rant, I just believe that in order for the app to have a successful future, it should be supporting what WordPress is already known for. Otherwise, Tumblr, Posterous and a slew of other platforms who are thinking more &#8220;mobile&#8221; could gain a significant portion of the WordPress market share.</p>
<p>It seems to me that there are five major components of WordPress that just aren&#8217;t supported by the app yet.</p>
<p><strong>1. Custom Post Types</strong><br />
This is a big one. WordPress introduced them in June 2010 with version 3.0 and we still don&#8217;t have them supported in the iOS app. This is probably the biggest upset of the five since it has been around for over a year and involves the very core of WordPress: Writing posts.</p>
<p><strong>2. Widgets</strong><br />
Seriously? Yes, seriously. Currently, there is no way to add, modify or remove widgets from your WordPress site using the iOS app. Some may disagree that this belongs on my list, but I think it&#8217;s deserving. Widgets were introduced in version 2.2 and are one of the core things that makes WordPress unique and attractive. The mobile app should reflect WordPress&#8217;s existing core strengths to differentiate itself from other mobile players.</p>
<p><strong>3. Post Formats</strong><br />
Post formats were introduced in version 3.1 and I think it was an excellent addition. It took the Custom Post Types functionality from version 3.0 and expanded it even further. We even saw the birth of &#8220;Tumblogs&#8221;, or WordPress themes that function like Tumblr sites, all because of Post Formats. Hell, I can&#8217;t even use the default <a href="http://wordpress.org/extend/themes/twentyeleven" target="_blank">Twentyeleven</a> theme effectively on iOS because support for Post Formats is still missing. This would be a huge improvement.</p>
<p><strong>4. Custom Fields (Post Meta)</strong><br />
Some plugins and advanced themes take advantage of Custom Fields on WordPress posts and pages. Although not always crucial, this is another capability that already makes WordPress unique and is part of core functionality so I believe it should be a part of the mobile strategy.</p>
<p><strong>5. Theme Options<br />
</strong>Almost every theme these days has a variety of Theme Options. And I&#8217;m not just talking about the &#8220;Theme Options&#8221; item under the Appearance menu, but also Header, Background, Sidebars and any other options page available for a particular theme. Why is this last on my list? Because Theme Options aren&#8217;t exactly critical for delivering content, which is what mobile is really all about: creating and publishing content quickly while on-the-go.</p>
<p>Jump on over to the <a href="http://ios.forums.wordpress.org/" target="_blank">WordPress iOS App Forum</a> to join the conversation or be part of the solution.</p>
]]></content:encoded>
			<wfw:commentRss>http://frankiejarrett.com/2011/08/whats-the-future-of-the-wordpress-ios-app/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Page Caching using disk: enhanced
Database Caching using disk: basic
Object Caching 1065/1209 objects using disk: basic

Served from: frankiejarrett.com @ 2012-05-19 16:26:27 -->
