Skip to content
PHP Ecosystem
Explore

HasTitle

API reference › HTML Attribute › Global › HasTitle

traitUIAwesome\Html\Attribute\Global\HasTitle
Sourcesrc/Global/HasTitle.php
Used by 4 types

Provides an immutable API for the title attribute.

See also: https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/title.

MethodDescriptionDefined by
title()Sets the title attribute.HasTitle
public function title(string|Stringable|UnitEnum|null $value): static

Sets the title attribute.

Parameters

ParameterTypeDescription
$valuestring|Stringable|UnitEnum|nullAdvisory title text, or null to remove the attribute.

Returns

static: New instance with the updated title attribute.