Category: Wordpress

Check if Current Page is in Tree

September 8th, 2010

This is a really useful little snippet I found in the WordPress Codex. It allows us to check whether a page is within a specified tree, e.g. whether a page is a certain ID or if it is a subpage of that ID. Here's the function: function is_tree($pid) { global $post; // load details about this page $anc = get_post_ancestors( $post->ID ); foreach($anc as $ancestor) { if(is_page() && $ancestor == $pid) { return true; } } if(is_page()&&(is_page($pid))) ...

WP Utility Short Codes Plugin – Free

August 29th, 2010
wpus-banner

This plugin lets you very easily insert utility boxes and buttons, which can be used for any number of things, such as drawing your visitors to important information. For example, download links. View Live Demo Download

Minimum Word Count for WordPress Posts

August 26th, 2010

If you wish to set a minimum word count for your posts (this can be useful for a variety of things, including maintaining a clean layout), simply add the following snippet to your functions.php file and set the number to whatever you wish. function minWord($content) { global $post; $content = $post->post_content; if (str_word_count($content) < 100 ) //set this to the minimum number of words wp_die( __('Error: your post is below the minimum word count.') ); } add_action('publish_post', 'minWord'); If an author tries to publish a post with fewer ...

Simple Share – Easy Social Sharing

August 10th, 2010
screenshot

Simple Social Network Sharing for WordPress Simple Sharing is an easy to use social network sharing plugin that adds a “share” box to each of your individual posts, allowing your readers to easily share your post over many of the most popular social sharing networks. But What’s Different from Others Unlike many social network sharing plugins, Simple Share floats just to the left of your content and scrolls with the page as readers scroll, keeping it always in view. Why does this matter? Readers have ...

Full IE Support in WordPress Font Uploader v1.2

July 26th, 2010
font-uploader-thumb-v1.2

I'm pleased to announce that my premium WordPress Font Uploader plugin now has full support for fonts in Internet Explorer. 100% Cross Browser Compatible Fonts This means that you can now display any font anywhere you like on your website, while being assured that it will work no matter what browser your site visitor is using. Check out the screencast below for a demonstration of this new feature. Convert your fonts To convert your fonts to a .eot, readable by Internet Explorer, use the link ...

Page 1 of 512345