HTML DOM align Property
Complete Image Object Reference
Definition and Usage
The align property sets or returns how to align an image according to the
surrounding text.
Syntax
imageObject.align=left|right|top|middle|bottom
|
Example
The following example aligns the image to the right according to the
surrounding text:
<html>
<body>
<img id="compman" src="compman.gif" alt="Computerman" />
<p>Some text. Some text. Some text. Some text.</p>
<script type="text/javascript">
document.getElementById("compman").align="right";
</script>
</body>
</html>
|
Try-It-Yourself Demos
Set the
alignment of an <image> element
Complete Image Object Reference
 |

|
|
See why there are 20,000+ Ektron integrations worldwide.
Request an INSTANT DEMO or download a FREE TRIAL today. |
|
|
|