left 예제
<style>
#hz {
position: absolute;
width: 500px;
height: 100px;
background-color: coral;
color: white;
}
</style>
<button onclick="homzzang()">클릭</button>
<div id="hz"><h1>홈짱닷컴 Homzzang.com</h1></div>
<script>
function homzzang() {
document.getElementById("hz").style.left = "100px";
}
</script>
결과보기
정의
.
기본값:
반환값: 를 나타내는 문자열
CSS속성:
CSS버전: CSS
4.
브라우저 지원.
구문
[접근]
[설정]
[속성값]