YoastSEO_Vendor\Psr\Http\Message
ServerRequestInterface::getAttribute() public Yoast 1.0
Retrieve a single derived request attribute.
Retrieves a single derived request attribute as described in getAttributes(). If the attribute has not been previously set, returns the default value as provided.
This method obviates the need for a hasAttribute() method, as it allows specifying a default value to return if the attribute is not found.
{} Это метод класса: ServerRequestInterface{}
Хуков нет.
Возвращает
Разное
. Ничего.
Использование
$ServerRequestInterface = new ServerRequestInterface(); $ServerRequestInterface->getAttribute( $name, $default );
- $name(строка) (обязательный)
- The attribute name.
- $default(разное)
- Default value to return if the attribute does not exist.
Заметки
- Смотрите: getAttributes()
Код ServerRequestInterface::getAttribute() ServerRequestInterface::getAttribute Yoast 16.1.1
public function getAttribute($name, $default = null);