Xml::tag()
Builds an XML tag
Xml::tag(string $name, array|string|null $content = '', array $attr = null, string $indent = null, int $level = 0): string
Parameters
Name | Type | Default | Description |
---|---|---|---|
$name |
string |
– | Tag name |
$content |
array |string |null |
'' |
Scalar value or array with multiple lines of content or |
$attr |
array |
null |
An associative array with additional attributes for the tag |
$indent |
string |
null |
Indentation string, defaults to two spaces or |
$level |
int |
Indentation level |
Return type
string