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

Unlimited number of child pages using wp_list_pages

wordpress snippet

Adding this snippet to the sidebar.php of your wordpress theme will use wp_list_pages to display all child pages regardless of depth. This is something I have not found online and needed for a current theme I’m working on, enjoy!

read more

highlight post_states within admin posts and pages

wordpress snippet

Adding this snippet to the functions.php of your wordpress theme will highlight the posts_states within the admin post and page sections.

read more

Remove the comments count column from pages

wordpress snippet

Adding this snippet to the functions.php of your wordpress theme will remove the comments count column from pages admin page.

read more

Get the page ID by the page name

wordpress snippet

Add the first snippet into the functions.php and the second snippet into one of your wordpress template files. This snippet will allow you to return a page ID by the page name. Don’t forget to change PAGE_NAME to the name of the page you would like to return the ID of.

read more

Disable Tinymce HTML editor excluding array of users

wordpress snippet

Adding this snippet to the functions.php of your wordpress theme will disable tinyMCE for everyone but the specified list of users. This is an updated version of this snippet ( Disable Tinymce ).

read more

Change admin area “pagination” posts per page

wordpress snippet

Adding this snippet to the functions.php of your wordpress theme will let you adjust the number of posts display within the admin area. By default wordpress will display 20 posts at a time within the admin area but you can change the number for the variable $per_page to display more or less.

read more