ํฐ์คํ ๋ฆฌ ๋ทฐ
<%@ page language="java" contentType="text/html; charset=EUC-KR"
pageEncoding="EUC-KR"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=EUC-KR">
<title>ํ๊ทธ๋ช
์ผ๋ก ์์๊ฒ์</title>
<script type="text/javascript">
window.onload = function() {
//pํ๊ทธ๋ฅผ ๊ฒ์ํ๋ค.
var pList = document.getElementsByTagName("p");
//์์ฐจ์ ์ผ๋ก ์ธ๋ฑ์ค๋ก ๊ฐ๊ฐ์ p๋ฅผ ์ฐพ๋๋ค.
for(i =0 ; i < pList.length; i++) {
//pํ๊ทธ์ ์ฒซ์งธ ์์ ๋
ธ๋๋ ํ
์คํธ ๋
ธ๋์ด๋๊น.
var txt = pList[i].childNodes[0].nodeValue;
view.innerHTML += txt + "<br/>";
}
}
</script>
<style type="text/css">
#view {
float: right;
width: 300px;
height: 500px;
border: 1px solid black;
overflow: auto;
}
</style>
</head>
<body>
<h2>ํ๊ทธ๋ช
์ผ๋ก ์์ ๊ฒ์</h2>
<div id="view"></div>
<p>'์ง์ค๊ฒ์'์ด CCTV ๊ณต๊ฐ๋ฅผ ํตํด ์ฌ์ค๋ก ๋๋ฌ๋ฌ๋ค.</p>
<p>aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa</p>
<p>bbbbbb</p>
<p>ccccccccccc</p>
<p>1111111111111</p>
</body>
</html>
'JS' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
Ajax ์์_์ฒ๋ฆฌํ์ด์ง (0) | 2010.07.12 |
---|---|
Ajax ์์ (0) | 2010.07.12 |
DOM ๊ฐ์ฒด 01 (0) | 2010.07.09 |
JSON ์ด์ฉํ ๊ฐ์ฒด toString (0) | 2010.07.09 |
JSON ์ด์ฉํ ๊ฐ์ฒด์์ฑ (0) | 2010.07.09 |
- Total
- Today
- Yesterday
- ์๋ฆฌ
- ๊ธฐํ
- ์๋ธ๋ฆฟ
- JSON
- JS
- I Don't Care
- Java
- ์๋ฐ์คํฌ๋ฆฝํธ
- 8๋ง์ผ
- ๋ฉ๋ฐฐํ
- ํจ์
- MS-SQL
- MySQL
- php
- Servlet
- ์นด๋ฐ์จ๋ผ์ธ
- ์น์์ด์ ์
- JavaScript
- ์ธํจ์ด
- ๋์ค
- 2ne1
- JSP
- asp
- Ajax
- JSTL
- ๊ฒฝ์ ์ฉ์ด
- ์์์ฌ์ด๋
- jQuery
- ๋ณต๊ทผ์ด๋
- EL
์ผ | ์ | ํ | ์ | ๋ชฉ | ๊ธ | ํ |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | |||
5 | 6 | 7 | 8 | 9 | 10 | 11 |
12 | 13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | 22 | 23 | 24 | 25 |
26 | 27 | 28 | 29 | 30 | 31 |