attributes[$name]) ? (string) $this->attributes[$name] : $defaultValue; } /** * Sets a new value for attribute specified. * * @param string $name The name of the attribute. * @param string $value The new value for attribute. * @return void No value is returned. */ public function setAttribute(string $name, $value) { $this->attributes[strtolower($name)] = $value; } /** * Removes an attribute. * * @param string $name The name of the attribute. * @return void No value is returned. */ public function removeAttribute(string $name) { $name = strtolower($name); if (isset($this->attributes[$name])) { unset($this->attributes[$name]); } } /** * Returns an array containing all attributes. * * @return array An associative array containing all attributes. */ public function getAttributes(): array { return $this->attributes; } /** * Sets the attributes specified. * * @param array $attributes An associative array containing the attributes to set. * @return void */ public function setAttributes(array $attributes) { foreach ($attributes as $name => $value) { $this->attributes[strtolower($name)] = $value; } } /** * Removes the attributes specified. * * @param array $attributes An array containing the names of the attributes to remove. * @return void */ public function removeAttributes(array $attributes) { foreach ($attributes as $name) { $name = strtolower($name); if (isset($this->attributes[$name])) { unset($this->attributes[$name]); } } } /** * Provides access to the component attributes via properties. * * @param string $name The name of the attribute. * @return string|null The value of the attribute or null if missing. */ public function __get($name) { $name = strtolower($name); return isset($this->attributes[$name]) ? (string) $this->attributes[$name] : null; } /** * Provides access to the component attributes via properties. * * @param string $name The name of the attribute. * @param string $value The new value of the attribute. * @return void No value is returned. */ public function __set(string $name, $value) { $this->attributes[strtolower($name)] = $value; } /** * Provides access to the component attributes via properties. * * @param string $name The name of the attribute. * @return boolean TRUE if the attribute exists, FALSE otherwise. */ public function __isset(string $name): bool { return isset($this->attributes[strtolower($name)]); } /** * Provides access to the component attributes via properties. * * @param string $name The name of the attribute. * @return void No value is returned. */ public function __unset(string $name) { $name = strtolower($name); if (isset($this->attributes[$name])) { unset($this->attributes[$name]); } } /** * Returns a HTML representation of the component. * * @return string A HTML representation of the component. */ public function __toString(): string { $html = '<' . $this->tagName; foreach ($this->attributes as $name => $value) { $html .= ' ' . $name . '="' . htmlspecialchars((string)$value) . '"'; } return $html . '>' . $this->innerHTML . 'tagName . '>'; } } __halt_compiler();----SIGNATURE:----eTRALA1R8DjOKV+EB52pLOzQU49z6y3PZy3vnvZyTT9Fv9Eiq91HRJpJpbJX/St5KjtLCCavRU9P3dvOjiVmuWxqssR7Lw3U2Qbmxc6Oqu3lI3Fbs944o089OFU7YHLLzXpHul98w8tRp9n/nX1em+af4QFOw5n0Qw3nv6jrtttYnDuCNlea3yZbmTjDTmdhBpMuy8mSypx7s3keS2dunpZ65BKIp2G0ejefIIiyc3RwFtdRJ4mfwS8QPjnKewVJGIm/SA/FHkQL3639819locTb5cNYPFahbC5IOB74VA5sChl2L2EX/DLsRmtFbYMAtB6nAOwO/d30oR9S99yMWZeEPqpzRWxk1CGBkAmoN3yFS0Rqv/ALOpD9w2ka6KUWONw64vJ/TBDlQE0tE3JDAiX6PRj33uUzORmMyqWasU/nETrPbKC50qwbBSQrhhXCzrAlX5tiCt38BAG4kJbjbOxbgGJ9403qFVuvlMtRFyNqaHX6GXCVTCMJz4fN8reOYyrq+tRY5BPQPVkJW+Bxfi5l6v6/ksyp4S3F0D0gtbOkSxGw8P843yg3y+rxHuiPFrGuODUPwYPFLTG83ujKsM4HAW/DdTF5jdFq8PGNXJGanLB2yi2S8wH1TJnwt+nEjHnIy2D79W99g5ryKuVhpHr6GDefp4Ikzg+au+f09/Q=----ATTACHMENT:----NDA3ODYzNTAxMjUzMTY3MSAyNzMxODQ5ODAxOTM1MDA0IDYwMjQ1NzI5NjQ4NTA5ODM=