updated   : May 15, 2012
we now have 588 snippets
By : , on November 21, 2010 11:54 pm

List top commentators

wordpress snippet

Adding the first block of PHP code to the functions.php of your wordpress theme will let you call the function in the bellow block of code anywhere in your theme to display the top five commentators.

read more
By : , on 8:00 pm

Separate trackbacks from comments

wordpress snippet

Adding this code to your comments.php replacing the default comments loop will allow you to separate trackbacks from comments.

read more
By : , on 2:00 pm

Add delete and spam actions

wordpress snippet

The first snippet of code should be added to your functions.php of your wordpress theme. Once added you will need to open comments.php and add the second snippet of code to the location you wish to display the delete and spam links. These links will only be displayed for users with the ability to edit posts.

read more
By : , on 9:00 am

Duplicate content comment pages

wordpress snippet

Adding this PHP code to the functions.php of your wordpress theme will prevent duplicated content as a result of multiple comments pages.

read more
By : , on November 20, 2010 11:00 pm

Prevent access to wp-admin

wordpress snippet

Adding this code to your functions.php will redirect subscribers away from wp-admin to the home page.

read more
By : , on 4:00 pm

Firefox opensearch and your blog

wordpress snippet

Add this code to a text editor and save as opensearch.xml then upload to your root dir. This will let users add your website as a search engine within Firefox like Google, Bing, Wikipedia and others. Now visitors can change their search option and select your blog.

read more
By : , on 9:00 am

Remove windows live writer

wordpress snippet

Adding this PHP code to your wordpress functions.php will remove windows live writer from the wordpress header.

read more
By : , on November 19, 2010 8:00 pm

Check if user is logged in

wordpress snippet

Using this PHP code in your wordpress theme will let you display alternate content to users that are logged in. You could use this to display a custom message to logged in users eg: register or welcome message for members.

read more