로그인

이메일
비밀번호
DaeYoung's Blog : 위치로그 : 태그 : 방명록 : 관리자 : 새글쓰기
Java Script 간단한 글래스 만들기
Web/JavaScript, (2007년 04월 26일 14시 46분)
<SCRIPT LANGUAGE="JavaScript">
<!--
//자바스크립트 클래스 정의

Member = function(name, id){ //클래스 정의(생성자에 해당함)
        this.name = name ;
        this.id = id ;
}

Member.prototype.setValue = function(newName, newId){
        /* prototype는 클래스에 매소드를 정의할때 사용된다.*/
        this.name = newName ;
        this.id = newId ;
}

Member.prototype.getName = function(){
        return this.name;
}

Member.prototype.getId = function(){
        return this.id;
}


var mem = new Member("홍길동","hong"); //객체선언
document.write(mem.name); // 홍길동
document.write(mem.id); // 아이디

mem.setValue("임꺽정","imguk"); // set매소드로 값입력
document.write(mem.getName()); // 값반환 //임꺽정
document.write(mem.getId()); //imguk

//-->
</SCRIPT>
http://laedu.net/trackback/9
DaeYoung's Blog 블로그에 오신것을 환영해요^^
웹기반 프로그래밍에 관한 것들을 모을 예정이었는데..
«   2024년 08월   »
        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
Javax.mail 참고 사이트.
C# TextBox KeyDown, KeyPr...
SID가 여러개 있을때 'ORA...
https://scrapingmaster.blogg...
https://scrapingmaster.blogg.. 2023년
expertdecoders.com.
expertdecoders.com 2023년
expertdecoders.
expertdecoders 2023년
best decaptcha service.
best decaptcha service 2023년
capcher.
capcher 2023년
6
119
1016031