-
Notifications
You must be signed in to change notification settings - Fork 1
Wolfy87 edited this page Nov 23, 2010
·
2 revisions
$(string element, object context).css(object properties)
element - The CSS selector string to your element.
context - If supplied, the context in which you wish the selection to take place.
properties - The CSS properties you wish to assign.
Returns all of the CSS properties of the element.
Set the color of all paragraph tags to red
$('p').css({color: '#FF0000'});
Get the color of the paragraph tags
alert($('p').css().color);