[Javascript 기초] 자바스크립트 기초

2009. 6. 25. 13:36 - 에릭투스

1. 일정관리 프로그램 만들어볼것.
2. 오늘 자바스크립트 마지막시간.

1) 내장객체에 대해 알아보자!!

2) 자바스크립트는 에러가 발생시
 경고없이 그냥 안나옴.. -_-;;;;;

javascript
javascript에서는 ArrayList 가 엄써요....

1. Array
 1). 생성시 [] 사용
  ex) new Array(length)
    array=["value"];
 2) method
  1. pop();   : 마지막 element를 배열에서 뽑아낸다.
       : Array 에서 마지막 element를 뽑아내 버리는 것.
 
  2. push(); : 집어넣는것.

  3. reverse(); : element를 거꾸로 뒤집는 메소드

  4. shift(); : 맨처음 element를 뽑아내는 메소드

  5. sort(); : 정렬하는 메소드.

* 배열이 넘쳐도 들어간다...-_-;;;


2. screen
 1). screen.width   : 현재해상도<가로>.
 2). screen.height : 현재해상도 <세로>
 3) screen.availWidth : 가능한 해상도<가로>
 4) screen.availHeight) : 가능한 해상도<세로>

3. Navigator
  : 사용자 컴퓨터 정보를 가져올때 사용.
1). appName : return application name (netscape / IE)
 ex) alert(navigator.appName);

Property      : Description IE F O
appCodeName   : Returns the code name of the browser 4 1 9
appMinor     : Version Returns the minor version of the browser 4 No No
appName     : Returns the name of the browser 4 1 9
appVersion     : Returns the platform and version of the browser 4 1 9
browserLanguage  : Returns the current browser language 4 No 9
cookieEnabled   : Returns a Boolean value that specifies whether cookies are enabled in the browser 4 1 9
cpuClass      : Returns the CPU class of the browser's system 4 No No
onLine       : Returns a Boolean value that specifies whether the system is in offline mode 4 No No
platform      : Returns the operating system platform 4 1 9
systemLanguage  : Returns the default language used by the OS 4 No No
userAgent     : Returns the value of the user-agent header sent by the client to the server 4 1 9
userLanguage    : Returns the OS' natural language setting 4 No 9

Navigator Object Methods

4. Location
 
  hash       : Sets or returns the URL from the hash sign (#) 4 1 9
  host        : Sets or returns the hostname and port number of the current URL 4 1 9
  hostname     : Sets or returns the hostname of the current URL 4 1 9
  href        : Sets or returns the entire URL 4 1 9
  pathname     : Sets or returns the path of the current URL 4 1 9
  port        : Sets or returns the port number of the current URL 4 1 9
  protocol      : Sets or returns the protocol of the current URL 4 1 9
  search       : Sets or returns the URL from the question mark (?) 4 1 9
 ex)
   alert(location.host);
   alert(location.port);
   alert(location.protocol);
   alert(location.hostname);


--------------------------------------------------------------------------------------------------------
js06.html
--------------------------------------------------------------------------------------------------------
style="display : none" : 안보이게 하기.

1. Object.style.display = " value";
 inline : 같은 줄.
 block : 다음줄로.

2. Object.style.visibility = " value ";


3. Object.style.backgroundColor=color-name|color-rgb|color-hex|transparent

4. javascript를 따로 만들어 참조하게 할수 있다.


jdk는 기본으로 깔리고.

<J2SE>기본
<J2EE> : 지금부터 밥벌이~~
      : Server에서 돌아가는 web application을 만드는것.
      : Server - Client 사용할수 있게끔도와주는 것이 J2EE
      : 서버의 대표적이고 , Opensource인  Tomcat

Sun사에서 api문서만 받고, tomcat을 사용할 것임.

* Webserver(java사용하여)
 : Tomcat , weblogic, Zeus(티맥스soft), resin
Tomcat : 서블릿하구 jsp를 돌아가게 하는 ...녀석..

core : 개발목적으로 사용시.
Deployer:  서버만 돌리고싶을때


다른 카테고리의 글 목록

웹 개발/자바스크립트 기초 카테고리의 포스트를 톺아봅니다