wordpress snippets last updated   : October 6, 2014
we now have 641 snippets

Add and remove wordpress user roles

wordpress snippet

With WordPress you can add and remove roles very easily. The first snippet will add a new role called “manager” with some basic capabilities. You can view the WordPress roles and capabilities page for more extensive details on the capabilities available that you can assign to a custom role. The second snippet will remove some of the existing roles “editor, author, contributor, subscriber” however this could also remove a custom role. NOTE: if you remove an existing role it will be gone! So please be careful when removing roles.

read more

Change the author slug, URL base

wordpress snippet

Adding this to the functions.php of your wordpress theme will change the default mysite.com/author/name to mysite.com/profile/name, however you can change this to user or anything that you would like.

read more

Display comments in admin to authors own posts only

wordpress snippet

Only show the comments to the authors own posts within the wordpress admin, hide all other comments. This is a great little snippet if you want authors to look after their own comments. Just add this snippet to the functions.php of your wordpress theme and you are ready to go.

read more

Remove support for specific post type features

wordpress snippet

Adding this snippet to the functions.php of your wordpress theme will remove support for the specific features bellow from specified post types. Change the word ‘post’ to anything you like including a custom post type name or the default post, page.

read more

Give author capabilities including editing other authors posts

wordpress snippet

Adding this snippet to the functions.php of your wordpress theme will allow authors to edit other users posts.

read more

Display author avatar within posts or pages

wordpress snippet

Adding this snippet to your wordpress theme within the loop will display the current authors avatar.

read more
jqsnipp.com | we just launched jquery snippets website