GM addStyle: Difference between revisions

From GreaseSpot Wiki
Jump to navigationJump to search
m title underscore template
LouCypher (talk | contribs)
m categorized
Line 14: Line 14:


  GM_addStyle("body { color:red; }");
  GM_addStyle("body { color:red; }");
[[Category:API Reference|A]]

Revision as of 03:25, 6 December 2006

Template:Underscore

Syntax

GM_addStyle( css )

Description

Adds a string of CSS to the document.

Creates a new <style> element, adds the given CSS to it, and inserts it into the <head>.

Examples

GM_addStyle("body { color:red; }");