⇦ Back to Document classMethod addStyleDeclaration
public \Joomla\CMS\Document\Document
addStyleDeclaration
(mixed $content, mixed $type = 'text/css')
Adds a stylesheet declaration to the page
Parameters
- string $content Style declarations
- string $type Type of stylesheet (defaults to 'text/css')
Returns
- \Joomla\CMS\Document\Document instance of $this to allow chaining
Since
Deprecated
Method addStyleDeclaration - Source code
public function addStyleDeclaration($content, $type = 'text/css')
{
$type = strtolower($type);
if (empty($this->_style[$type])) {
$this->_style[$type] = array();
}
$this->_style[$type][md5($content)] = $content;
return $this;
}