Eine auf WordPress spezialiserte Suchmaschine für Entwickler und Theme-Autoren



user_has_cap ›

Seit3.7.0
Veraltetn/v
apply_filters( 'user_has_cap', $this->allcaps, $caps, $args, $this )
Parameter: (4)
  • (bool[]) $allcaps Array of key/value pairs where keys represent a capability name and boolean values represent whether the user has that capability.
    Erforderlich: Ja
  • (string[]) $caps Required primitive capabilities for the requested capability.
    Erforderlich: Ja
  • (array) $args { Arguments that accompany the requested capability check. @type string $0 Requested capability. @type int $1 Concerned user ID. @type mixed ...$2 Optional second and further parameters, typically object ID. }
    Erforderlich: Ja
  • (WP_User) $user The user object.
    Erforderlich: Ja
Definiert in:
Codex:

Dynamically filter a user's capabilities.





Quellcode

$capabilities = apply_filters( 'user_has_cap', $this->allcaps, $caps, $args, $this );