Javascript Reference
Categories: STYLE

javascript STYLE margin

@Aug. 15, 2009, 12:33 p.m.
margin Firefox/Netscape/NN 6 IE 4 Chrome/Safari/DOM 2  

 

Read/Write  

This is a shortcut property that can set the margin widths of up to four edges of an element with one statement. A margin is space that extends beyond the border of an element to provide extra empty space between adjacent or nested elements, especially those that have border attributes set. You may supply one to four space-delimited margin values. The number of space-delimited values determines which sides receive the assigned margins.

 
Example
 
document.getElementById("logoWrapper").style.margin = "5px 8px";
 
Value

This property accepts one, two, three, or four space-delimited values inside one string, depending on how many and which margins you want to set.  Values for the margins can be lengths, percentages of the next outermost element size, or the auto constant.

 
Default

0

<a href=https://vscialisv.com/>cialis generic tadalafil
fumpImmib - 3 years
com69q0l

cehmft6x

b38d0s0fa

xrcnouvw

uxdiv3yx
jibjabst - 2016-02-24

Powered by Linode.