Syntax
void addStyleDeclaration( $content, $type )where:
Argument | Data type | Description | Default |
---|---|---|---|
$content | string | Stylesheet content. | |
$type | string | MIME type of stylesheet. | 'text/css' |
Example
To add a CSS style to the document, you could use:$doc =& JFactory::getDocument();
$style = 'BODY {'
. 'background: #00ff00;'
. 'color: rgb(0,0,255);'
. '}';
$doc->addStyleDeclaration( $style );
No comments:
Post a Comment