WordPress Themes for 02/01

Music WordPress Theme

The Music WordPress Theme has a really nice feel to it. I haven’t seen to many (if any at all) WordPress themes like this one. It has a toned down grunge feel but is still clean and well structured, unlike many grunge designs I’ve seen.

Read more…

Stylesheet Directory Link Tag

One difficulty of designing WordPress themes you plan to let others use, is linking to images within the template directory (where the stylesheet is). Fortunately, WordPress provides a tag for doing just that.

<?php echo(get_bloginfo('template_directory')); ?>

/images/ is the images folder inside your theme folder. You can link to a page in that folder (comments.php) or something inside the images folder:

<img src="<?php echo(get_bloginfo('template_directory')); ?>/images/rss_icon.gif" alt="" />

We can make linking to an image even easier:

<?php
$bloginfo_link = get_bloginfo('template_directory');
$image_link = $bloginfo_link . '/images';
?>

<img src="<?php echo $image_link; ?>/rss_icon.gif" alt="" />

We assign the template directory path to the variable $bloginfo_link and then put the directory path and the image folder path together.

The easiest way to display ‘Home’ as a navigation link, Period.

Here is the easiest way to display a homepage link in the navigation bar of your WordPress site. I can guarantee that you won’t find an easier way out there.

The code:

<ul>
<li><?php if ( is_home() ) { ?> class="current_page_item"<? } ?></li>
<?php wp_list_pages('title_li='); ?>
</ul>

It’s pretty obvious how this code works. If the current page is the blog’s homepage, then it’ll add a special class to the list item to mark it as the current page. If it isn’t, the navigation button displays normally.

That’s it. No extra pages, no special configuration. The easiest way to display ‘Home‘ as a navigation link, period.

Setup WordPress Locally On Mac OS X

When designing WordPress themes, it’s nice to be able to store them locally to test them instead of uploading files to a web server (though Transmit makes it quite easy). In this tutorial, you’ll learn how to set up WordPress locally on your Mac and then manage multiple blogs with their own themes.

Read more…

WordPress Tutorials Collection

Dan Philibin, previous owner of WPCustomization, has donated his collection of WordPress tutorials from the site’s blog that he pulled prior to the sale. This collection includes tutorials, quick tips, and tricks for WordPress.

I’ll be publishing these tutorials slowlythroughout the next few days so stay tuned and enjoy.

Oh and a big thanks to Dan!

WP Easy Admin Plugin

A couple of days ago I wrote a tutorial on how to display content for only the admin to see. I kept thinking a bit more about what else I could do with this WordPress trick and I ended up creating the WP Easy Admin plugin. I’m no PHP guru, and I’ve never made a WordPress plugin before, so go easy on me!

Read more…

Socialize Me! Plugin

Socialize Me is a new WordPress plugin created by Wayne Smallman that lets your readers connect to you easily. Socialize Me detects the referring page, and if it finds that the referring page is from a social network, such as Twitter, it’ll display a link to your profile on that network.

Read more…

Tutorial: Content For Admin Only

For a couple of days now, I’ve being wondering how to display something only for the admin to see, when the admin is logged in. This could come in handy to display links to the WP admin panel or stats page.

So I did a bit of research and I found exactly what I was looking for:

<?php global $user_ID; if( $user_ID ) : ?>
<?php if( current_user_can('level_10') ) : ?>

Stats

<?php else : ?>
<?php endif; ?>
<?php endif; ?>

The code above will display “Stats” with a link to a stats page, but only for the admin, when the admin is logged on.

You can modify the code above to display links only for certain types of users, such as Contributors, Authors, Editors, etc, by changing the “level_10“. Read more about WordPress Roles and Capabilities here.

This is just a quick little tutorial I wanted to share with you guys! Enjoy. Oh and if you know of any other ways to use this tutorial, please share!