HTML DOM Marquee vspace Property
The HTML DOM Marquee vspace Property is used to set or return the value of the vspace attribute of the <marquee> Tag. The vspace attribute is used to specify the vertical margin around the marquee element.
Syntax
It returns the marquee vspace Property.
marqueeObject.vspace;
It sets the marquee vspace Property.
marqueeObject.vspace = "px/%"
Property Values
- px: Specify vertical space around marquee.
- %: Specify vertical space around marquee.
Return Value: It returns a numeric value that represents the number of vertical spaces around an element.
Note: The marquee vspace Property is not supported in HTML 5.
Example: Below HTML code helps to return the marquee vspace Property.
HTML
<!DOCTYPE html> < html > < head > < title > HTML DOM Marquee vspace property </ title > </ head > < body style = "text-align:center;" > < h1 style = "color:green;" > w3wiki </ h1 > < h2 >DOM Marquee vspace Property</ h2 > < marquee id = "marqueeID" direction = "right" loop = "3" bgcolor = "green" vspace = "10%" > w3wiki:A computer Science Portal for Beginner </ marquee > < button onclick = "btnClick()" > Return vspace property </ button > < p id = "sudo" ></ p > < script > function btnClick() { var txt = document.getElementById("marqueeID").vspace; document.getElementById("sudo").innerHTML = txt + "%"; } </ script > </ body > </ html > |
Output:
Supported Browsers:
- Google Chrome
- Internet Explorer
- Firefox
- Apple Safari
- Opera