<?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>WP First Aid &#187; WordPress</title>
	<atom:link href="http://wpfirstaid.com/tag/wordpress/feed/" rel="self" type="application/rss+xml" />
	<link>http://wpfirstaid.com</link>
	<description>It&#039;s WordPress ... anything is possible!</description>
	<lastBuildDate>Tue, 17 Jan 2012 16:47:01 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Remove Comment Form Website Section</title>
		<link>http://wpfirstaid.com/2012/01/remove-comment-form-website-section/</link>
		<comments>http://wpfirstaid.com/2012/01/remove-comment-form-website-section/#comments</comments>
		<pubDate>Tue, 17 Jan 2012 16:47:01 +0000</pubDate>
		<dc:creator>The Doctor</dc:creator>
				<category><![CDATA[Functions]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[add_filter]]></category>
		<category><![CDATA[comment_form]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://wpfirstaid.com/?p=1122</guid>
		<description><![CDATA[From time to time an interesting Five-Minute-FixTM comes along that sparks a great reason to add another WordPress Tips post. The idea for this tip started with this comment at BuyNowShop.com: &#8230; how to remove the website section when leaving a reply/comment &#8230; The solution may be obvious to some and can be readily derived [...]]]></description>
			<content:encoded><![CDATA[<p>From time to time an interesting <a href="http://buynowshop.com/five-minute-fix/" title="Five Minute Fix @ BuyNowShop">Five-Minute-Fix<sup>TM</sup></a> comes along that sparks a great reason to add another <a href="http://wpfirstaid.com/category/tips/" title="WPFirstAid WordPress Tips">WordPress Tips</a> post. The idea for this tip started with <a href="http://buynowshop.com/five-minute-fix/comment-page-1/#comment-11155">this comment</a> at <a href="http://buynowshop.com/" title="BuyNowShop.com">BuyNowShop.com</a>:</p>
<blockquote><p>&#8230; how to remove the website section when leaving a reply/comment &#8230;</p></blockquote>
<p>The solution may be obvious to some and can be readily derived from the information found on the WordPress codex page for the `<a href="http://codex.wordpress.org/Function_Reference/comment_form" title="Codex: comment_form">comment_form</a>` function, but if you are new to <a href="http://wordpress.org/" title="WordPress-dot-org">WordPress</a> and/or not familiar with writing a function to use with `<a href="http://codex.wordpress.org/Function_Reference/add_filter" title="Codex: add_filter">add_filter</a>`, here is a very simple and working snippet to use in your theme:</p>
<div class="aside-toggler open"><span class="open-aside tip">To see the <em>tip</em> click here.</span><span class="close-aside tip">To hide the <em>tip</em> click here.</span>
                         </div><div class="bnsia aside tip open">
<pre class="brush: php; title: ; notranslate">
function wpfa_remove_comment_website_section(){
    $commenter = wp_get_current_commenter();
    $req = get_option( 'require_name_email' );
    $aria_req = ( $req ? &quot; aria-required='true'&quot; : '' );
    $fields =  array(
        'author' =&gt; '&lt;p class=&quot;comment-form-author&quot;&gt;' . '&lt;label for=&quot;author&quot;&gt;' . __( 'Name' ) . '&lt;/label&gt; ' . ( $req ? '&lt;span class=&quot;required&quot;&gt;*&lt;/span&gt;' : '' ) .
                    '&lt;input id=&quot;author&quot; name=&quot;author&quot; type=&quot;text&quot; value=&quot;' . esc_attr( $commenter['comment_author'] ) . '&quot; size=&quot;30&quot;' . $aria_req . ' /&gt;&lt;/p&gt;',
        'email'  =&gt; '&lt;p class=&quot;comment-form-email&quot;&gt;&lt;label for=&quot;email&quot;&gt;' . __( 'Email' ) . '&lt;/label&gt; ' . ( $req ? '&lt;span class=&quot;required&quot;&gt;*&lt;/span&gt;' : '' ) .
                    '&lt;input id=&quot;email&quot; name=&quot;email&quot; type=&quot;text&quot; value=&quot;' . esc_attr(  $commenter['comment_author_email'] ) . '&quot; size=&quot;30&quot;' . $aria_req . ' /&gt;&lt;/p&gt;',
        'url'    =&gt; '' /** removes website section */,
    );
    return $fields;
}
add_filter( 'comment_form_default_fields', 'wpfa_remove_comment_website_section' );
</pre>
<p></div><script type="text/javascript">
            /* <![CDATA[ */
            jQuery( document ).ready( function(){
                jQuery( ".aside-toggler" ).click( function(){
                    jQuery( this ).toggleClass( "open" ).toggleClass( "closed" ).next( ".aside" ).slideToggle( "slow", function(){
                        jQuery( this ).toggleClass( "open" ).toggleClass( "closed" );
                    });
                });
            });
            /* ]]&gt; */
            </script>
<p>Ideally, this will be placed in the &#8216;functions.php&#8217; file of your theme, but better yet this should be included in the <a href="http://wpfirstaid.com/2011/04/wordpress-child-themes/" title="WordPress Child-Themes">Child-Theme</a> you created of the theme you want to modify.</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfirstaid.com/2012/01/remove-comment-form-website-section/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>No-Title Sticky Post-Format Posts?!</title>
		<link>http://wpfirstaid.com/2011/12/no-title-sticky-post-format-posts/</link>
		<comments>http://wpfirstaid.com/2011/12/no-title-sticky-post-format-posts/#comments</comments>
		<pubDate>Fri, 09 Dec 2011 21:28:28 +0000</pubDate>
		<dc:creator>The Doctor</dc:creator>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[add_theme_support]]></category>
		<category><![CDATA[post-formats]]></category>
		<category><![CDATA[post_class]]></category>
		<category><![CDATA[sticky posts]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://wpfirstaid.com/?p=1098</guid>
		<description><![CDATA[Making sure to test all of the combinations these three items can create.]]></description>
			<content:encoded><![CDATA[<p>Say what?! Seriously?</p>
<p>Yes, seriously. Although this sort of thing is not too likely to exist in the wild here are a few tips and idea to keep in mind when developing a theme.</p>
<p>Let&#8217;s start from the end with <em>&#8216;post-format&#8217;</em> posts and work our way back to the beginning. It wasn&#8217;t all that long ago WordPress introduced default post-formats that could be easily added to themes. Here&#8217;s a one-liner to put in your functions.php file that does it all, well it&#8217;s a good <a href="http://codex.wordpress.org/Post_Formats#Adding_Theme_Support" title="Add Theme Support for Post Formats">example from the codex</a> showing two post-formats:</p>
<pre class="brush: plain; title: ; notranslate">add_theme_support( 'post-formats', array( 'aside', 'gallery' ) )</pre>
<div class="aside-toggler closed"><span class="open-aside post-formats">To read more about Post Formats, click here</span><span class="close-aside post-formats">To hide the <em>Post Formats</em> click here.</span>
                         </div><div class="bnsia aside post-formats closed">There are nine (9) default <em>&#8216;post-formats&#8217;</em> as of this writing; there may be more added in the future but these work well. The number of ways end-users might use them is not much less than the ideas they can imagine.</p>
<p>Following is the complete &#8220;supported&#8221; list. You can <a href="http://codex.wordpress.org/Post_Formats#Supported_Formats" title="Supported Post Formats">visit the codex</a> for what some might consider their recommended usages.</p>
<ul>
<li>aside</li>
<li>gallery</li>
<li>link</li>
<li>image</li>
<li>quote</li>
<li>status</li>
<li>video</li>
<li>audio</li>
<li>chat</li>
</ul>
<p></div>
<p>Post-formats have been around since WordPress <a href="http://codex.wordpress.org/Version_3.1">Version 3.1</a>, if you are not familiar with them yet you should go back and read more about them.</p>
<p>Our next step back is to <a href="http://codex.wordpress.org/Sticky_Posts" title="Sticky Posts">Sticky Posts</a> introduced back in <a href="http://codex.wordpress.org/Version_2.7">version 2.7</a>. If you are not familiar with sticky posts then definitely take a few moments to read the articles linked to &#8230; I can wait.</p>
<p>So far, so good &#8230; right? Good!</p>
<p>Now let&#8217;s get to the beginning of the post title: No-Title; and, yes, this is something that should be addressed when developing a theme. <a href="http://en.wikipedia.org/wiki/The_Shadow" title="obligatory obscure reference ... read Wikipedia article: The Shadow" target="_blank">The Shadow</a> knows &#8230; otherwise one may never know the imagination of the end-user, or if their personal taste demands one (or many) posts are published without a title. Generally speaking, each of these items are handled well enough on their own but what happens when you combine them? If you have thoroughly tested your theme then most any combination of these elements should have been easily and clearly addressed; most of which can be done with simple CSS, too.</p>
<p>The key CSS elements to address for these items are the following:</p>
<ul>
<li>.format-aside</li>
<li>.format-gallery</li>
<li>.format-< post-format > &#8211; substitute < post-format > with the appropriate term</li>
<li>.sticky</li>
</ul>
<p>There may, or may not, be a theme CSS element used for a post without a title but that is well beyond the scope of this post; just remember to test each <em>&#8216;post-format&#8217;</em> with and without a title.</p>
<p>Now last, but not least, the simple CSS element to remember for the final testing: <em>&#8216;.format-< post-format >.sticky&#8217;</em> &#8230; again substituting the <em>< post-format ></em> for *all* of the <em>&#8216;post-formats&#8217;</em> used in the theme. Note there is no space between, for example, <em>.format-aside</em> and <em>.sticky</em> the element would be: <em>.format-aside.sticky</em> &#8230; these elements are automatically generated by WordPress if the theme uses the `<em><a href="http://codex.wordpress.org/Function_Reference/post_class" title="post_class function" target="_blank">post_class</a></em>` function correctly.</p>
<p>Granted this was a bit long written but hopefully helpful. It&#8217;s just something I found that required a lot more to properly address than what I first suspected as I was updating my theme <a href="http://buynowshop.com/themes/desk-mess-mirrored/" title="Desk Mess Mirrored" target="_blank">Desk Mess Mirrored</a> to version 2.0.</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfirstaid.com/2011/12/no-title-sticky-post-format-posts/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Filtering WP Title</title>
		<link>http://wpfirstaid.com/2011/11/filtering-wp-title/</link>
		<comments>http://wpfirstaid.com/2011/11/filtering-wp-title/#comments</comments>
		<pubDate>Wed, 30 Nov 2011 20:19:36 +0000</pubDate>
		<dc:creator>The Doctor</dc:creator>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[apply_filters]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[wp_title]]></category>

		<guid isPermaLink="false">http://wpfirstaid.com/?p=1087</guid>
		<description><![CDATA[A recent recommendation, starting with WordPress 3.3, from the WordPress Theme Review Team reads: Themes are REQUIRED to use wp_title filter to filter wp_title() (RECOMMENDED), or pass argument to wp_title() (OPTIONALLY), in order to modify document title content This has been discussed, worked through, and for the most part sorted out &#8230; but there doesn&#8217;t [...]]]></description>
			<content:encoded><![CDATA[<p>A recent recommendation, starting with WordPress 3.3, <a href="http://make.wordpress.org/themes/2011/11/10/wordpress-3-3-proposed-guidelines-revisions/" title="WordPress 3.3 Proposed Guidelines Revisions">from the WordPress Theme Review Team</a> reads:</p>
<blockquote><p>Themes are REQUIRED to use wp_title filter to filter wp_title() (RECOMMENDED), or pass argument to wp_title() (OPTIONALLY), in order to modify document title content</p></blockquote>
<p>This has been discussed, worked through, and for the most part sorted out &#8230; but there doesn&#8217;t appear to be any sort of example code to work from. This presented an opportunity to have a look around the <a href="http://codex.wordpress.org/Main_Page" title="WordPress Codex">WordPress codex</a> and the source code for some ideas how to filter the `<a href="http://codex.wordpress.org/Plugin_API/Filter_Reference/wp_title" title="Plugin API/Filter Reference/wp title">wp_title</a>` function.</p>
<p>Essentially, the idea behind the code (below) is to take a basic function call of `<a href="http://codex.wordpress.org/Function_Reference/wp_title" title="Function Reference/wp title">wp_title</a>` add some relevant text (a la default themes: <a href="http://wordpress.org/extend/themes/twentyten" title="WordPress Twenty Ten Theme">Twenty Ten</a> / <a href="http://wordpress.org/extend/themes/twentyeleven" title="WordPress Twenty Eleven Theme">Twenty Eleven</a>) then filter it back into the function; and finally to echo this to the HTML &lt;title&gt; tag.</p>
<div class="aside-toggler closed"><span class="open-aside wpfa-wp-title-code">To see the <em>WPFA WP Title code</em> click here.</span><span class="close-aside wpfa-wp-title-code">To hide the <em>WPFA WP Title code</em> click here.</span>
                         </div><div class="bnsia aside wpfa-wp-title-code closed">
<pre class="brush: php; title: ; notranslate">&lt;?php
/**
* WPFA WP Title
*
* Utilizes the `wp_title` filter to add text to the default output
* @link http://codex.wordpress.org/Plugin_API/Filter_Reference/wp_title
*
* @package WPFA_WP_Title
* @since 0.1
* @link https://gist.github.com/1410493
*/
if ( ! function_exists( 'wpfa_wp_title' ) ) {
    function wpfa_wp_title() {
            global $page, $paged;
            // Default title
            $title_text = wp_title( '|', false, 'right' ) . get_bloginfo( 'name' );

            // Add the blog description (tagline) for the home/front page.
            $site_tagline = get_bloginfo( 'description', 'display' );
            if ( $site_tagline &amp;&amp; ( is_home() || is_front_page() ) )
                $title_text .= &quot; | $site_tagline&quot;;

            // Add a page number if necessary:
            if ( $paged &gt;= 2 || $page &gt;= 2 )
                $title_text .= ' | ' . sprintf( __( 'Page %s', 'wpfa-wp-title-textdomain' ), max( $paged, $page ) );

            // Use `apply_filters` on `wp_title` and echo
            $wpfa_wp_title = apply_filters( 'wp_title', $title_text );
            echo $wpfa_wp_title;
    }
}
// End WPFA WP Title
?&gt;</pre>
<p></div>
<p>Hopefully this will be useful, or maybe it will not &#8230; but it will be found in the next release of Desk Mess Mirrored as that is the theme where I first wrote and tested it with.</p>
<p>Enjoy!</p>
<div class="aside-toggler open"><span class="open-aside note">To see the <em>note</em> click here.</span><span class="close-aside note">To hide the <em>note</em> click here.</span>
                         </div><div class="bnsia aside note open">PS: Note the <a href="https://gist.github.com/1410493" title="WPFA WP Title - github:gist">github:gist link</a> in the code sample &#8230; feel free to download it from there, as well as copying it from here. The Doctor.</div>
]]></content:encoded>
			<wfw:commentRss>http://wpfirstaid.com/2011/11/filtering-wp-title/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Enqueue Plugin Custom Stylesheet</title>
		<link>http://wpfirstaid.com/2011/11/enqueue-plugin-custom-stylesheet/</link>
		<comments>http://wpfirstaid.com/2011/11/enqueue-plugin-custom-stylesheet/#comments</comments>
		<pubDate>Tue, 15 Nov 2011 20:46:25 +0000</pubDate>
		<dc:creator>The Doctor</dc:creator>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[add_action]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[is_readable]]></category>
		<category><![CDATA[plugin_dir_path]]></category>
		<category><![CDATA[plugin_dir_url]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[wp_enqueue_scripts]]></category>
		<category><![CDATA[wp_enqueue_styles]]></category>

		<guid isPermaLink="false">http://wpfirstaid.com/?p=1072</guid>
		<description><![CDATA[Now that is a bit of a handful to grab onto &#8230; but the code and concept is relatively straight forward and easy to implement. As I was recently updating some of my plugins in preparation for WordPress 3.3 I decided to better implement the style elements being used in these plugins. The current best-practice [...]]]></description>
			<content:encoded><![CDATA[<p>Now that is a bit of a handful to grab onto &#8230; but the code and concept is relatively straight forward and easy to implement.</p>
<p>As I was recently updating some of my plugins in preparation for WordPress 3.3 I decided to better implement the style elements being used in these plugins. The current best-practice methods point to using the `wp_enqueue_scripts` hook with the `wp_enqueue_styles` function. Let&#8217;s get our eyes on a snippet for this:</p>
<pre class="brush: php; title: ; notranslate">function WPFA_Styles() {
        wp_enqueue_style( 'WPFA-Plugin-Style', plugin_dir_url( __FILE__ ) . 'wpfa-plugin-style.css', array(), '0.1', 'screen' );
}
add_action( 'wp_enqueue_scripts', 'WPFA_Styles' );</pre>
<p>We create a function to enqueue our stylesheet; then we use `add_action` to hook into `wp_enqueue_scripts` and we&#8217;re done &#8230; or are we?</p>
<p>What if we wanted to let the end-user add their own styles to the plugin CSS elements but not have them over-written with the next plugin update? Easy, just add another `wp_enqueue_style` into the `WP_Styles` function like this:</p>
<pre class="brush: php; title: ; notranslate">function WPFA_Styles() {
        wp_enqueue_style( 'WPFA-Plugin-Style', plugin_dir_url( __FILE__ ) . 'wpfa-plugin-style.css', array(), '0.1', 'screen' );
        wp_enqueue_style( 'WPFA-Plugin-Custom-Style', plugin_dir_url( __FILE__ ) . 'wpfa-plugin-custom-style.css', array(), '0.1', 'screen' );
}
add_action( 'wp_enqueue_scripts', 'WPFA_Styles' );</pre>
<p>This is fine, but what if the custom stylesheet does not exist? Although it will not cause any significant issues there is no reason to actually enqueue a file that does not exist. The solution to this is straight forward as well, just check if the file is available to be used &#8230; but how?</p>
<p>Let&#8217;s look at the complete example to see where I add the `is_readable` conditional check:</p>
<pre class="brush: php; title: ; notranslate">/**
 * Enqueue Plugin Styles
 *
 * Adds plugin stylesheet and allows for additional custom stylesheet to be added by end-user. Custom stylesheet is only enqueued if it is available to be used.
 *
 * @package     WPFA_Styles
 * @link        http://wpfirstaid.com/2011/11/enqueue-plugin-custom-stylesheet/
 * @version     0.1
 * @author      Edward Caissie &lt;thedoctor@wpfirstaid.com&gt;
 * @copyright   Copyright (c) 2010-2011, Edward Caissie
 *
 * @internal    Note: all stylesheets enqueued in this manner are expected to be in the root folder of the plugin.
 */
function WPFA_Styles() {
        /** Enqueue Style Sheets */
        wp_enqueue_style( 'WPFA-Plugin-Style', plugin_dir_url( __FILE__ ) . 'wpfa-plugin-style.css', array(), '0.1', 'screen' );
        // Only enqueue if available
        if ( is_readable( plugin_dir_path( __FILE__ ) . 'wpfa-plugin-custom-style.css' ) ) {
            wp_enqueue_style( 'WPFA-Plugin-Custom-Style', plugin_dir_url( __FILE__ ) . 'wpfa-plugin-custom-style.css', array(), '0.1', 'screen' );
        }
}
add_action( 'wp_enqueue_scripts', 'WPFA_Styles' );</pre>
<p>Note the use of `plugin_dir_path` in the conditional check, this is key as the `is_readable` function requires the path and will not work using the URL.</p>
<p>This may appear as a <a href="http://edwardcaissie.com/2010/08/mallory-everest-ideas/">Mallory-Everest idea</a>, but there have been use-cases where an additional custom stylesheet solved the issues at hand. Hopefully this will be of use to you.</p>
<p><div class="aside-toggler closed"><span class="open-aside wordpress-codex-references">To see the <em>WordPress Codex References</em> click here.</span><span class="close-aside wordpress-codex-references">To hide the <em>WordPress Codex References</em> click here.</span>
                         </div><div class="bnsia aside wordpress-codex-references closed"><br />
add_action &#8211; <a href="http://codex.wordpress.org/Function_Reference/add_action">http://codex.wordpress.org/Function_Reference/add_action</a><br />
plugin_dir_path &#8211; <a href="http://codex.wordpress.org/Function_Reference/plugin_dir_path">http://codex.wordpress.org/Function_Reference/plugin_dir_path</a><br />
plugin_dir_url &#8211; <a href="http://codex.wordpress.org/Function_Reference/plugin_dir_url">http://codex.wordpress.org/Function_Reference/plugin_dir_url</a><br />
wp_enqueue_scripts &#8211; <a href="http://codex.wordpress.org/Function_Reference/wp_enqueue_script">http://codex.wordpress.org/Function_Reference/wp_enqueue_script</a><br />
wp_enqueue_styles &#8211; <a href="http://codex.wordpress.org/Function_Reference/wp_enqueue_styles">http://codex.wordpress.org/Function_Reference/wp_enqueue_styles</a><br />
</div><br />
<div class="aside-toggler closed"><span class="open-aside php-functions">To see the <em>PHP Functions</em> click here.</span><span class="close-aside php-functions">To hide the <em>PHP Functions</em> click here.</span>
                         </div><div class="bnsia aside php-functions closed"><br />
is_readable &#8211; <a href="http://www.php.net/manual/en/function.is-readable.php">http://www.php.net/manual/en/function.is-readable.php</a><br />
</div></p>
]]></content:encoded>
			<wfw:commentRss>http://wpfirstaid.com/2011/11/enqueue-plugin-custom-stylesheet/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Start Using WordPress Beta</title>
		<link>http://wpfirstaid.com/2011/10/start-using-wordpress-beta/</link>
		<comments>http://wpfirstaid.com/2011/10/start-using-wordpress-beta/#comments</comments>
		<pubDate>Wed, 12 Oct 2011 15:20:15 +0000</pubDate>
		<dc:creator>The Doctor</dc:creator>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[beta]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://wpfirstaid.com/?p=1060</guid>
		<description><![CDATA[The basics, as a general guideline, on how to start using the latest WordPress beta version.]]></description>
			<content:encoded><![CDATA[<p>Just as I have been doing for the last several versions I will be updating to run the most recent version of the WordPress beta (version 3.3-beta1 as of this writing) live on this site as well as all of the other domains I own where WordPress is installed.</p>
<p>Although I have complete confidence in the stability of the beta versions I would still only suggest / recommend this practice to those with a reasonable knowledge of PHP and the ability to recover from any potential catastrophic disaster (read: BACK-UP everything first!!!).</p>
<p>Here are the basics, as each version changes these may not be exactly the same but should still serve as a general guideline:</p>
<ol>
<li>Back up your WordPress installation (all of it).</li>
<li>Using your preferred text editor, open the /wp-includes/version.php file in core to edit.</li>
<li>Find and change <em>$wp_version</em> to a &#8216;point value&#8217; greater than the current version, for example: 3.3-alpha.</li>
<li>Go to your the Administration Panels (&#8220;Dashboard&#8221;) of your WordPress installation.</li>
<li>Scroll to the bottom of the page and click on the “stay updated” link in the bottom-right corner. (Refresh the page if the link is not there.)</li>
<li>Follow any additional prompts, such as updating the database, etc.</li>
</ol>
<p>You should now be running the latest version of &#8216;trunk&#8217;.</p>
<p>Of course there is a widely used plugin (<a title="Plugin: WordPress Beta Tester" href="http://wordpress.org/extend/plugins/wordpress-beta-tester/">WordPress Beta Tester</a>) by <a title="Peter Westwood" href="http://profiles.wordpress.org/users/westi/">Westi</a> that does most if not all of the above for you &#8230; I just like to do this manually.</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfirstaid.com/2011/10/start-using-wordpress-beta/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Do Not Display Comments HTML Tags</title>
		<link>http://wpfirstaid.com/2011/08/do-not-display-comments-html-tags/</link>
		<comments>http://wpfirstaid.com/2011/08/do-not-display-comments-html-tags/#comments</comments>
		<pubDate>Sun, 07 Aug 2011 22:24:54 +0000</pubDate>
		<dc:creator>The Doctor</dc:creator>
				<category><![CDATA[Functions]]></category>
		<category><![CDATA[comment_form]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://wpfirstaid.com/?p=1052</guid>
		<description><![CDATA[A standard function found in many themes is the comment_form. This is a core function of WordPress that produces a standard comment form generally consisting of text fields for the name and email address and a textarea for the actual comment. You will also find there are some standard text outputs produced by this function [...]]]></description>
			<content:encoded><![CDATA[<p>A standard function found in many themes is the <em>comment_form</em>. This is a <a href="http://codex.wordpress.org/Function_Reference/comment_form" title="Codex: comment_form">core function</a> of <a href="http://wordpress.org" title="WordPress">WordPress</a> that produces a standard comment form generally consisting of text fields for the name and email address and a textarea for the actual comment. You will also find there are some standard text outputs produced by this function as well, one of those is the allowed HTML tags that can be used in the form.</p>
<pre>You may use these HTML tags and attributes: &lt;a href="" title=""> &lt;abbr title=""> &lt;acronym title=""> &lt;b> &lt;blockquote cite=""> &lt;cite> &lt;code> &lt;del datetime=""> &lt;em> &lt;i> &lt;q cite=""> &lt;strike> &lt;strong></pre>
<p>If you do not want to display this text it is actually very easy to do. It can be done with a line of CSS or a minor edit to the theme in question. The following is based on using the comment_form function in its default state:</p>
<pre class="brush: php; title: ; notranslate">&lt;?php comment_form(); ?&gt;</pre>
<p>To hide the message above with CSS, add one of the following to the end of your style.css file:</p>
<pre class="brush: css; title: ; notranslate">p.form-allowed-tags { display: none; }</pre>
<pre class="brush: css; title: ; notranslate">p.form-allowed-tags { visibility: hidden; }</pre>
<p>Using the display property &#8220;removes&#8221; the block of text whereas using the visibility property simply &#8220;hides&#8221; the text leaving the block being filled with nothing. Which method is best will be more due to aesthetics than anything else.</p>
<p>If you want to edit your theme files, look into the comments.php template file (again a standard default naming convention, your theme may vary), and find the default code noted above and change it to the following:</p>
<pre class="brush: php; title: ; notranslate">&lt;?php comment_form( 'comment_notes_after=' ); ?&gt;</pre>
<p>Always remember, any edits you make to the theme may be over-written with the theme&#8217;s next update &#8230; always back-up your work.</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfirstaid.com/2011/08/do-not-display-comments-html-tags/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
		<item>
		<title>Dynamic Copyright Revisited</title>
		<link>http://wpfirstaid.com/2011/06/dynamic-copyright-revisited/</link>
		<comments>http://wpfirstaid.com/2011/06/dynamic-copyright-revisited/#comments</comments>
		<pubDate>Mon, 13 Jun 2011 16:55:50 +0000</pubDate>
		<dc:creator>The Doctor</dc:creator>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[apply_filters]]></category>
		<category><![CDATA[bns_dynamic_copyright]]></category>
		<category><![CDATA[dynamic_copyright]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://wpfirstaid.com/?p=1031</guid>
		<description><![CDATA[An updated version of the dynamic copyright function found in BuyNowShop.com themes by Cais.]]></description>
			<content:encoded><![CDATA[<p>A while back I wrote an article about a function to generate a <a title="Dynamic Copyright" href="http://wpfirstaid.com/2010/02/dynamic-copyright/">dynamic copyright</a> to display in themes.  Although I imagine the function can be adapted to be used elsewhere, the original intent was to place the function call in the footer of any given theme.</p>
<p>The function itself can be found in all the themes currently available from <a title="Cais' Profile at WordPress.org" href="http://profiles.wordpress.org/users/cais">Cais</a> at <a title="BuyNowShop.com" href="http://buynowshop.com">BuyNowShop.com</a> via the <a title="WordPress" href="http://wordpress.org">WordPress</a> Extend <a title="WordPress Extend Themes repository" href="http://wordpress.org/extend/themes/">Themes repository</a>. There have been a few minor changes to the function since it was introduced; and, it is just recently undergoing much more dramatic changes.</p>
<p>That being the case, I thought this would be a great opportunity to revisit the function and discuss what has changed since the last time I wrote about it here.</p>
<div class="aside-toggler closed"><span class="open-aside bns-dynamic-copyright-code">To see the <em>BNS Dynamic Copyright code</em> click here.</span><span class="close-aside bns-dynamic-copyright-code">To hide the <em>BNS Dynamic Copyright code</em> click here.</span>
                         </div><div class="bnsia aside bns-dynamic-copyright-code closed"></p>
<pre class="brush: php; title: ; notranslate">// Start BNS Dynamic Copyright
if ( ! function_exists( 'bns_dynamic_copyright' ) ) {
  function bns_dynamic_copyright( $args = '' ) {
      $initialize_values = array( 'start' =&gt; '', 'copy_years' =&gt; '', 'url' =&gt; '', 'end' =&gt; '' );
      $args = wp_parse_args( $args, $initialize_values );

      /* Initialize the output variable to empty */
      $output = '';

      /* Start common copyright notice */
      empty( $args['start'] ) ? $output .= sprintf( __('Copyright') ) : $output .= $args['start'];

      /* Calculate Copyright Years; and, prefix with Copyright Symbol */
      if ( empty( $args['copy_years'] ) ) {
        /* Get all posts */
        $all_posts = get_posts( 'post_status=publish&amp;order=ASC' );
        /* Get first post */
        $first_post = $all_posts[0];
        /* Get date of first post */
        $first_date = $first_post-&gt;post_date_gmt;

        /* First post year versus current year */
        $first_year = substr( $first_date, 0, 4 );
        if ( $first_year == '' ) {
          $first_year = date( 'Y' );
        }

      /* Add to output string */
        if ( $first_year == date( 'Y' ) ) {
        /* Only use current year if no posts in previous years */
          $output .= ' &amp;copy; ' . date( 'Y' );
        } else {
          $output .= ' &amp;copy; ' . $first_year . &quot;-&quot; . date( 'Y' );
        }
      } else {
        $output .= ' &amp;copy; ' . $args['copy_years'];
      }

      /* Create URL to link back to home of website */
      empty( $args['url'] ) ? $output .= ' &lt;a href=&quot;' . home_url( '/' ) . '&quot; title=&quot;' . esc_attr( get_bloginfo( 'name', 'display' ) ) . '&quot; rel=&quot;home&quot;&gt;' . get_bloginfo( 'name', 'display' ) .'&lt;/a&gt;  ' : $output .= ' ' . $args['url'];

      /* End common copyright notice */
      empty( $args['end'] ) ? $output .= ' ' . sprintf( __('All rights reserved.') ) : $output .= ' ' . $args['end'];

      /* Construct and sprintf the copyright notice */
      $output = sprintf( __('&lt;span id=&quot;bns-dynamic-copyright&quot;&gt; %1$s &lt;/span&gt;&lt;!-- #bns-dynamic-copyright --&gt;'), $output );
      $output = apply_filters( 'bns_dynamic_copyright', $output, $args );

      echo $output;
  }
}
// End BNS Dynamic Copyright
</pre>
<p></div>
<p>What&#8217;s changed:</p>
<ol>
<li>A `function_exists` conditional check has been added</li>
<li>Better internationalization string formating has been applied.</li>
<li>Default arguments have been set to generate a common notice.</li>
<li>The `apply_filters` function has been implemented to allow for easier customization.</li>
</ol>
<p>Also to note, the defaults are now written slightly different than the orginal generated copyright notice structure. The following are the current defaults:</p>
<ul>
<li>&#8216;start&#8217; =&gt; &#8220;Copyright&#8221;</li>
<li>&#8216;copy_years&#8217; =&gt; the copyright symbol + the dynamically generated years with published posts</li>
<li>&#8216;url&#8217; =&gt; points to the top level domain with the web site title as anchor text</li>
<li>&#8216;end&#8217; =&gt; &#8220;All Rights Reserved.&#8221;</li>
</ul>
<p>All of these paramters are now easily customized using the common WordPress structure, for example:</p>
<pre class="brush: plain; title: ; notranslate">bns_dynamic_copyright( 'start=Mine, All Mine!&amp;end=This means you, scrapers!' );</pre>
<p>&#8230; would produce the following for this site (as of this writing):</p>
<blockquote><p>Mine, All Mine! © 2009-2011 <a title="WP First Aid" href="../" rel="home">WP First Aid</a> This means you, scrapers!</p></blockquote>
<p>Of course, the above may not be appropriate for your own website &#8230; or maybe it is.</p>
<p>All the same, feel free to implement this updated function; and, don&#8217;t forget to look for it in the next releases of themes from <a title="BuyNowShop.com" href="http://buynowshop.com">BuyNowShop.com</a></p>
<p>Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfirstaid.com/2011/06/dynamic-copyright-revisited/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Reset Your WordPress Test Site</title>
		<link>http://wpfirstaid.com/2011/01/reset-your-wordpress-test-site/</link>
		<comments>http://wpfirstaid.com/2011/01/reset-your-wordpress-test-site/#comments</comments>
		<pubDate>Sun, 23 Jan 2011 18:25:06 +0000</pubDate>
		<dc:creator>The Doctor</dc:creator>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[installation]]></category>
		<category><![CDATA[reset]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://wpfirstaid.com/?p=939</guid>
		<description><![CDATA[How to reset your WordPress test site in three easy steps.]]></description>
			<content:encoded><![CDATA[<p>Although resetting your <a href="http://wordpress.org">WordPress</a> installation is not common it is relatively easy to do. It is especially useful for test sites so this post may appeal to the <a href="http://wordpress.org/extend/themes/">WordPress Theme</a> authors more than most, but it is still very handy to keep <a title="Reset Your WordPress Test Site" href="http://wp.me/pIDVu-f9">bookmarked</a> for future reference. I will continue under the premise this is for a test site although the instructions are much the same for any current WordPress installation.</p>
<p>There are three basic steps to a reset:</p>
<ol>
<li>Drop all the database tables in the WordPress database.</li>
<li>Re-install WordPress.</li>
<li>Add test data.</li>
</ol>
<p>That was easy!</p>
<p>Now, let&#8217;s go into some more details.</p>
<p>In step 1. above I wrote &#8220;Drop all the database tables in the WordPress database&#8221;; this is easily accomplished via a straight forward MySQL command:</p>
<pre class="brush: plain; title: ; notranslate">DROP TABLE `wp_commentmeta`, `wp_comments`, `wp_links`, `wp_options`, `wp_postmeta`, `wp_posts`, `wp_terms`, `wp_term_relationships`, `wp_term_taxonomy`, `wp_usermeta`, `wp_users`;</pre>
<p>&#8230; or you can use the commonly found phpMyAdmin application if your hosting service provides it via your control panel. <strong>Be very careful with this step as it is non-recoverable</strong> unless you have a proper backup; all of your existing test site data (posts, pages, etc.) will be lost.</p>
<p>In step 2. above, you simply go to your test site. Follow the prompts to install WordPress. All of the files are still there, the installation just needs to be re-initialized.</p>
<p>Step 3. above can be accomplished in many ways, I would suggest simply importing the <a href="http://codex.wordpress.org/Theme_Unit_Test">Theme Unit Test</a> data as provided by WordPress.</p>
<p>Just follow the link; right-click; and, choose &#8220;Save &#8230; As&#8230;&#8221; Different browsers have different terms for this function but it should be clear which one to choose. For example, Firefox uses &#8220;Save Link As&#8230;&#8221;; Chrome uses &#8220;Save link as&#8230;&#8221;; and, Internet Explorer uses &#8220;Save Target As&#8230;&#8221; If you are importing your test data simply go to the Administration Panels and under Tools choose Import. If you have been through this process before it will be quite simple and proceed quickly. If you have not imported data into this site you will be prompted to install the <a href="http://wordpress.org/extend/plugins/wordpress-importer/">WordPress Importer</a>. Just follow the on-screen prompts in either case.</p>
<p>These are some additional optional actions you will most likely find very beneficial as well:</p>
<ul>
<li>Remove the initial default posts that WordPress creates during the installation process.</li>
<li>Re-activate/install these test plugins:
<ul>
<li><a href="http://wordpress.org/extend/plugins/theme-check/">Theme Check</a></li>
<li><a href="http://wordpress.org/extend/plugins/log-deprecated-notices/">Log Deprecated Notices</a></li>
<li><a href="http://wordpress.org/extend/plugins/debug-bar/">Debug Bar</a> (requires WordPress 3.1+)<sup>1, 2</sup></li>
<li><a href="http://wordpress.org/extend/plugins/bns-support/">BNS Support</a></li>
<li><a href="http://wordpress.org/extend/plugins/bns-login/">BNS Login</a></li>
</ul>
</li>
<li>Modify your test site default theme to include all the new <a href="http://codex.wordpress.org/Version_3.1">WordPress 3.1</a> Post Formats
<ul>
<li>For example, change line 81 in functions.php of  Twenty Ten to:
<pre class="brush: plain; first-line: 81; title: ; notranslate">add_theme_support( 'post-formats', array( 'aside', 'gallery', 'link', 'image', 'quote', 'status', 'video', 'audio', 'chat' ) );</pre>
</li>
<li>Update the Theme Unit Test posts as neeeded</li>
</ul>
</li>
</ul>
<div class="nota-bene">NB: The plugins listed above each serve important functions for testing purposes. I would suggest the first three as being a requirement for test sites. The two <a href="http://buynowshop.com/plugins/">BNS plugins</a> are recommended for testing and for functionality but as I wrote both I may be biased.</div>
<div class="nota-bene">
<ol>Amendments:</p>
<li>Jan 24, 2011: Edited to add link for Debug Bar in the plugins list.</li>
<li>Mar 22, 2011: Dropped <a href="http://wordpress.org/extend/plugins/debogger/">Debogger</a> link.</li>
</ol>
</div>
]]></content:encoded>
			<wfw:commentRss>http://wpfirstaid.com/2011/01/reset-your-wordpress-test-site/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>WordPress Christmas</title>
		<link>http://wpfirstaid.com/2010/12/wordpress-christmas/</link>
		<comments>http://wpfirstaid.com/2010/12/wordpress-christmas/#comments</comments>
		<pubDate>Wed, 22 Dec 2010 16:59:44 +0000</pubDate>
		<dc:creator>The Doctor</dc:creator>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[themes]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://wpfirstaid.com/?p=922</guid>
		<description><![CDATA[Merry Christmas 2010!]]></description>
			<content:encoded><![CDATA[<p>Just a little holiday cheer from the many people that contribute to the <a title="WordPress" href="http://wordpress.org">WordPress</a> project. If you are looking for a free WordPress Theme here is a quick search of the <a title="WordPress Themes" href="http://wordpress.org/extend/themes/">Extend Themes</a> repository that will give you some options:</p>
<p><a title="Christmas Themes" href="http://wordpress.org/extend/themes/search.php?q=Christmas">http://wordpress.org/extend/themes/search.php?q=Christmas</a></p>
<p>Of course, the plugin authors have their own merry making to add to the season as well and you can find a listing of the <a title="WordPress Plugins" href="http://wordpress.org/extend/plugins/">Extend Plugins</a> repository with this little search:</p>
<p><a title="Christmas Plugins" href="http://wordpress.org/extend/plugins/search.php?q=Christmas">http://wordpress.org/extend/plugins/search.php?q=Christmas</a></p>
<p>Don&#8217;t forget to use the &#8220;Sort by&#8221; function on the search pages to arrange the results to your preference.</p>
<p><a href="http://wpfirstaid.com/wp-content/uploads/2010/12/merry_christmas_cookies-11412.jpg"><img class="aligncenter size-full wp-image-933" title="merry_christmas_cookies-11412" src="http://wpfirstaid.com/wp-content/uploads/2010/12/merry_christmas_cookies-11412.jpg" alt="" width="300" height="300" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://wpfirstaid.com/2010/12/wordpress-christmas/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to Create a Pokersite on WordPress</title>
		<link>http://wpfirstaid.com/2010/12/how-to-create-a-pokersite-on-wordpress/</link>
		<comments>http://wpfirstaid.com/2010/12/how-to-create-a-pokersite-on-wordpress/#comments</comments>
		<pubDate>Thu, 16 Dec 2010 16:53:02 +0000</pubDate>
		<dc:creator>Jonas Adamson</dc:creator>
				<category><![CDATA[Contributed]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://wpfirstaid.com/?p=912</guid>
		<description><![CDATA[WordPress isn&#8217;t just great software for keeping and maintaining a personal blog but can also be a powerful tool for building and maintaining poker websites as well, whether they&#8217;re strategy guides, reviews of the best online poker sites, or forums. WordPress is open-source software so it&#8217;s not only free but thousands of developers have created [...]]]></description>
			<content:encoded><![CDATA[<p>WordPress isn&#8217;t just great software for keeping and maintaining a personal blog but can also be a powerful tool for building and maintaining poker websites as well, whether they&#8217;re strategy guides, reviews of the <a href="http://www.pokerlistings.com/online-poker-rooms">best online poker sites</a>, or forums. WordPress is open-source software so it&#8217;s not only free but thousands of developers have created plugins and tools that let you turn WordPress into a content management system for managing all sorts of websites.</p>
<p><a href="http://wpfirstaid.com/wordpress-services/installation/">Installing WordPress</a> is a snap, and most Web hosts now offer one-click installation that lets even non-technical users get up and running very quickly with their new site. Using pre-existing <a href="http://wordpress.org/extend/themes/">WordPress themes</a> and widgets enables you to assemble your site piece by piece through a drag-and-drop interface, with the end result being a slick new site that not only looks professionally-designed but also allows you to easily add new content and pages using just a Web browser.</p>
<p>WordPress also has a few cards up its sleeve for anyone using it to build poker sites, as its easier than ever to incorporate a wide range of features and functionality, far past simply adding pages for a <a href="http://www.pokerlistings.com/poker-stars">PokerStars review</a> or listing available poker bonuses. Developed by the same minds behind WordPress, BuddyPress is similar open-source software that enables site owners to add social networking features to their sites. </p>
<p>Since poker is at heart a social game, creating a pokersite with social networking features such as chat, messaging, and individual blogs for members can be a no-brainer, as it lets poker fans come together in a community setting and share their love of the game. It&#8217;s also a snap to install plugins that let users share their favorite hands (with graphics for cards), post the worst bad beat they&#8217;ve taken at the tables, and vote on polls and quizzes about what the best way to play certain hands in different situations. </p>
<p>By using all of the WordPress options available to you, a poker website that in the past might have cost thousands of dollars to develop and weeks or months to implement can be created for free, in just a day or two, with no real technical expertise needed. This is great news for both site owners and poker fans, as it means that more and more great poker sites will be created and developed over time.</p>
<p><a href="http://buynowshop.com/contact-us/for-advertising/" class="paid">Paid Contribution</a></p>
]]></content:encoded>
			<wfw:commentRss>http://wpfirstaid.com/2010/12/how-to-create-a-pokersite-on-wordpress/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

