wordpress snippets last updated   : January 29, 2015
we now have 646 snippets

Remove <br /> after wp_list_categories

wordpress snippet

Adding this PHP code to your wordpress theme will remove the <br /> from wp_list_category().

read more

Good robots.txt

wordpress snippet

This is a good example of a robots.txt to use with your wordpress installation. Bellow the first example is one from smashing magazine. Yes yes I know, I know, not the best robot drawing in the world! have a better one? send it along ill replace my robot with yours.

read more

Disable dashboard widgets

wordpress snippet

Adding this first block of code to the functions.php of your wordpress theme will disable select widgets within your dashboard. Bellow is a list of widgets you can add to the list if you wish to disable them.

read more

Create dashboard widget

wordpress snippet

Adding this PHP code to the functions.php of your wordpress theme will add your custom dashboard widget. This is just the basic building blocks of your own custom dashboard widget.

read more

Private posts for logged in users

wordpress snippet

Using this as your wordpress loop will display posts with the custom field of private only to users that are logged into your website.

read more

Notify members on new posts

wordpress snippet

Adding this PHP code snippet to the functions.php of your wordpress theme will notify users of new posts. Please note that this snippet is best used for low volume sites. Large websites should consider alternative options.

read more