Having trouble with how to filter the comment listing from WordPress back-end base on something else like user role?  Read this!

Sometime you might have custom role, let’s say co-editor, setup using members plugin in your WordPress.  And then you want to achieve  showing all comments only to the user who has administrator role but user with co-editor role sees only some of the comment.  You could use the below code to overcome this saturation.

Continue reading

Having trouble with how to filter the post listing from WordPress back-end base on something else like user role?  Read this!

Sometime you might have custom role, let’s say co-editor, setup using members plugin in your WordPress.  And then you want to achieve  showing all posts only to the user who has administrator role but user with co-editor role sees only some of the posts.  You could use the below code to overcome this saturation.
Continue reading

Today I am going to showing you how to add additional fields to WordPress back-end profile page.  Sometime you might need to add additional fields to the user profile page and you could use below code.

function add_more_profile_fields( $profileuser ) {
           //add your fields here
}

//call this action hook
add_action( 'show_user_profile', add_more_profile_fields );
add_action( 'edit_user_profile', add_more_profile_fields );

Continue reading

Using WordPress wp_nav_menu function you can display navigation menus on your site nicely.  You can even add the separators between each navigation menu.  It can be done by passing these arguments either “link_before, link_after” or “before, after” to your wp_nav_menu funtion.  However, you might face the problem with adding separators between each navigation menu. Continue reading

Below are a bunch of WordPress functions which will let you add your own admin menu to WordPress admin panel.

[code]
// add top level menu
add_menu_page(page_title, menu_title, capability, handle, [function], [icon_url]);

// add sub-menu pages
add_submenu_page(parent, page_title, menu_title, capability, file/handle, [function]);

// add Options sub-menu
add_options_page(page_title, menu_title, capability, handle, [function]);

// add Management sub-menu
add_management_page(page_title, menu_title, capability, handle, [function]);

// add Pages sub-menu
add_pages_page( page_title, menu_title, capability, handle, [function]);

// add Posts sub-menu
add_posts_page( page_title, menu_title, capability, handle, [function]);

// add Appearances sub-menu
add_theme_page( page_title, menu_title, capability, handle, [function]);
[/code]