Form
<div> ... </div>
Attributes
attribute |
default |
description |
id |
none |
specifies the unique ID |
class |
none |
specifies the style sheet class |
style |
none |
specifies the style sheet |
align |
left |
specifies the alignment |
Explanation
The div tag indicates the alignment of a division block text and the block-level section to apply CSS.
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=shift_jis">
<title>Sample</title>
<style type="text/css"><!--
div {
border:1px solid black;
}
--></style>
</head>
<body>
<h1>Sample</h1>
<div>
It's sample.
</div>
</body>
</html>