WP-角色和能力
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了WP-角色和能力相关的知识,希望对你有一定的参考价值。
Use this plugin:http://wordpress.org/extend/plugins/members/
Settings are here:
http://justintadlock.com/archives/2010/07/10/meta-capabilities-for-custom-post-types
http://codex.wordpress.org/Function_Reference/register_post_type
Gravity Form - Custom field
http://wpsmith.net/2011/plugins/how-to-create-a-custom-form-field-in-gravity-forms-with-a-terms-of-service-form-field-example/
Add this capabilities for every custom post type. [edit_post] => "edit_{$capability_type}" [read_post] => "read_{$capability_type}" [delete_post] => "delete_{$capability_type}" [edit_posts] => "edit_{$capability_type}s" [edit_others_posts] => "edit_others_{$capability_type}s" [publish_posts] => "publish_{$capability_type}s" [read_private_posts] => "read_private_{$capability_type}s" [delete_posts] => "delete_{$capability_type}s" [delete_private_posts] => "delete_private_{$capability_type}s" [delete_published_posts] => "delete_published_{$capability_type}s" [delete_others_posts] => "delete_others_{$capability_type}s" [edit_private_posts] => "edit_private_{$capability_type}s" [edit_published_posts] => "edit_published_{$capability_type}s" edit_members read_members delete_members edit_memberss edit_others_memberss publish_memberss read_private_memberss delete_memberss delete_private_memberss delete_published_memberss delete_others_memberss edit_private_memberss edit_published_memberss
以上是关于WP-角色和能力的主要内容,如果未能解决你的问题,请参考以下文章
用户角色 - 添加角色功能 php 片段 - Wordpress
Wordpress阻止访问wp admin€“wpsnipp.com网站你博客的Wordpress代码片段