property | {String/Object} | The String name of a css property, or an Object with key:value pairs |
value | {String} [optional] | The value to be set. Numerical values should include units. |
Current style value or DollarJS (chainable)
$('p').css('color')
$('p').css('color', '#336699')
$('p').css({ color: '#336699', fontSize: '14px' })
If property is a String and value is NOT passed, this will return the current value for that style property on the first element in the set
If property is a String and value is provided, this will set the value for that style property on all elements in the set
If property is an Object, styles will be set for each key:value pair on all elements in the set