Open kristineds opened 8 years ago
Another function WordPress® Function → current_user_can_for_blog() already exists in the WordPress® core.
I think this statement would work better if it comes after the documentation for each function. For instance, maybe in italics we can just say something like:
_See also: WordPress Core Function current_user_can_for_blog()
_
KB Article Creation Checklist
draft
and eitherquestions
ortutorials
draft
label, adddraft-finalized
label)draft-finalized
label, addpending
)pending
label, addpublished
label)Additional TODOs
Additional TODO list items go here.
This is a work in progress.
[intro]
Using the
current_user_cannot()
Functions2Member adds a new function to WordPress called
current_user_cannot()
. This is a special addition provided by s2Member that makes false testing easier for some. This conditional is used to determine if the current User does NOT have a specific Capability or Role.This function accepts two arguments:
$capability
. A WordPress® Capability ID ( i.e.access_s2member_level[0-9]+
,access_s2member_ccap_music
)$role
. A WordPress® Role ID ( i.e.s2member_level[0-9]+
,administrator
,editor
,author
,contributor
,subscriber
)_See also: WordPress Core Function
current_user_can()
_Using the
current_user_cannot_for_blog()
FunctionThis is a new function to WordPress added by s2Member called
current_user_cannot_for_blog()
. This conditional will determine if the current User does NOT have a specific Capability or Role, on a specific Blog within a Multisite Network.This function accepts three arguments:
$capability
. A WordPress Capability ID ( i.e.access_s2member_level[0-9]+
,access_s2member_ccap_music
)$role
. A WordPress Role ID ( i.e.s2member_level[0-9]+
,administrator
,editor
,author
,contributor
,subscriber
)$blog_id
. Required. A WordPress Blog ID (must be numeric)._See also: WordPress Core Function
current_user_can_for_blog()
_Using the
current_user_is()
FunctionA new function added to WordPress by s2Member called
current_user_is()
. This conditional will determine if the current User is/has a specific Role.This function accepts this argument:
$role
. A WordPress Role ID ( i.e.s2member_level[0-9]+
,administrator
,editor
,author
,contributor
,subscriber
)_See also: WordPress Core Function
current_user_can()
_Using the
current_user_is_for_blog()
FunctionA new function added to WordPress by s2Member called
current_user_is_for_blog()
. This conditional will determine if the current User is/has a specific Role, on a specific Blog within a Multisite Network.This function accepts two arguments:
$blog_id
. Required. A WordPress Blog ID (must be numeric).$role
. A WordPress Role ID ( i.e.s2member_level[0-9]+
,administrator
,editor
,author
,contributor
,subscriber
)_See also: WordPress Core Function
current_user_can_for_blog()
_Using the
current_user_is_not()
FunctionA new function added to WordPress by s2Member called
current_user_is_not()
. This conditional will determine if the current User is/does NOT have a specific Role.This function accepts this argument:
$role
. A WordPress Role ID ( i.e.s2member_level[0-9]+
,administrator
,editor
,author
,contributor
,subscriber
._See also: WordPress Core Function
current_user_can()
_Using the
current_user_is_not_for_blog()
FunctionA new function added to WordPress by s2Member called
current_user_is_not_for_blog()
. This conditional will determine if the current User is/does NOT have a specific Role, on a specific Blog within a Multisite Network.This function accepts two arguments:
$blog_id
. Required. A WordPress Blog ID (must be numeric).$role
. A WordPress Role ID ( i.e.s2member_level[0-9]+
,administrator
,editor
,author
,contributor
,subscriber
)_See also: WordPress Core Function
current_user_can_for_blog()
_See also:
[s2If /]
Simple Shortcode Conditionals