$formshasPermission()

Check if the current user has the permission name for the given $form

Usage

$bool = $forms->hasPermission(string $name, $form);

Arguments

NameType(s)Description
$namestring

Name of permission

$form

Return value

bool

Exceptions

Method can throw exceptions on error:

  • FormBuilderException


$forms methods and properties

API reference based on ProcessWire core version 3.0.251