javascript 수업

HTML과 CSS을 다이나믹하게 제어하는 본격 프로그래밍 언어

javascript 수업 HTML과 CSS을 다이나믹하게 제어하는 본격 프로그래밍 언어

내장 객체

본 수업은 폐지 예정입니다. 자바스크립트 언어 수업웹브라우저 자바스크립트로 수업이 리뉴얼 되었기 때문에 이것을 이용해주세요.

내장객체란?

시스템이 기본적으로 제공하는(built-in) 객체

Date Object : 시간과 관련된 Object

example1.html - (jsfiddle, github)

<!DOCTYPE html>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html;charset=utf-8" >
		<script type="text/javascript">
			var d1 = new Date(2002, 1, 18);
			var d2 = new Date(2011, 1, 18);

			alert(d1.getFullYear());
			alert(d2.getFullYear());
			alert(d2.getFullYear() - d1.getFullYear());
		</script>
	</head>
	<body></body>
</html>

String Object : 문자열

example2.html - (jsfiddle, github)

<!DOCTYPE html>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html;charset=utf-8" >
		<script type="text/javascript">
			var str = new String('egoing');
			var str = 'egoing';
			alert(str.length);
			alert(str.toUpperCase());
		</script>
	</head>
	<body></body>
</html>

Math Object : 수학과 관련된 객체

example3.html - (jsfiddle, github)

<!DOCTYPE html>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html;charset=utf-8" >
		<script>
			// 원주율
			var x = Math.PI;
			alert(x); 
			
			// 제곱근
			var y = Math.sqrt(16);
			alert(y);
		</script>
	</head>
	<body></body>
</html>

댓글

댓글 본문
작성자
비밀번호
  1. ZZYYTT
    http://www.mbtshoesonline.com
    http://www.kevindurant-shoes.us.com
    http://www.yeezy-boost.us.com
    http://www.goyardbags.us
    http://www.katespadehandbags-outlet.us.com
    http://www.yeezy-shoes.org.uk
    http://www.balenciaga.us.com
    http://www.ultraboost.us.com
    http://www.longchamphandbagsoutlets.com
    http://www.yesyeezy.shop......tml
    http://www.kd11.us
    http://www.adidas-tubular.us.com
    http://www.mlbjerseys.in.net
    http://www.yeezyboost-350v2.us.com
    http://www.jordan6.us.com
    http://www.supremeclothing.us
    http://www.balenciagashoes.us.org
    http://www.airmax90.us.org
    http://www.yeezyshoesuk.com
    http://www.goldengoosesneakers.us
    http://www.yeezy-boost350.us.com
    http://www.calvinkleinoutlet.us.com
    http://www.lebronjames-shoes.us.com
    http://www.supremehoodie.us.com
    http://www.yeezysuk.com
    http://www.yeezyboost.in.net
    http://www.goyardhandbags.us.com
    http://www.hermesbelts.com
    http://www.michael-kors-handbags.org.uk
    http://www.balenciagashoes.us.com
    http://www.coachoutletstorefactory.com
    http://www.jordan13.us.com
    http://www.rolex-replica.us.com
    http://www.hermes-belt.us.com
    http://www.coachoutletssale.com
    http://www.nhljerseysshop.us.com
    http://www.yesyeezy.shop......tml
    http://www.kyrie3.us.com
    http://www.michaelkors-outletonlines.us.com
    http://www.nike-shox.us.com
    http://www.cheap-airjordans.us.com
    http://www.jordanssneakers.us.com
    http://www.nikejordans.us.com
    http://www.nikebasketballshoes.us.com
    http://www.yesyeezy.shop
    http://www.adidasultraboost.us.org
    http://www.jordan11retro.us.com
    http://www.chromeheartsstore.us
    http://www.goldengoose.us.com
    http://www.paulgeorgeshoes.us.com
    http://www.yeezy-500.us.com
    http://www.michaeljordanshoes.us.com
    http://www.adidas-nmds.us.com
    http://www.nikeairforce1.us.com
    http://www.redbottom-shoes.us.com
    http://www.adidasstansmith.uk
    http://www.goldengoose-sneakers.com
    http://www.lebron16.us.com
    http://www.hermeshandbags.us.org
    http://www.adidasnmds.com
    http://www.offwhite.us.com
    http://www.yeezysshoes.us.com
    http://www.airjordanretro.uk
    http://www.lacostepolo.us.com
    http://www.toryburchs.us
    http://www.adidaszxflux.com
    http://www.monclerjackets.us
    http://www.yeezy-shoes.org
    http://www.long-champ.us.com
    http://www.kd11.us.com
    http://www.lebron16.us
    http://www.filashoes.org
    http://www.goyard-handbags.us.com
    http://www.hermes-birkin.us.com
    http://www.monclerjacket.net
    http://www.nikeair-max.us.com
    http://www.hardenshoes.us.com
    http://www.ferragamobelt.us.org
    http://www.converseoutlet.us.com
    http://www.chromehearts.name
    http://www.yeezy-shoes.ca
    http://www.linksoflondon.us.com
    http://www.goyardhandbags.org
    http://www.nikehuaracheshoes.us.com
    http://www.adidasiniki.us
    http://www.lacosteonlineshop.us.com
    http://www.jordanshoes.org.uk
    http://www.yesyeezy.shop/adidas-yeezy-desert-rat-500-blush-db2908-p-425.html
    http://www.caterpillarboots.us.com
    http://www.canada--goose.co.uk
    http://www.nike-hyperdunk.us.com
    http://www.guccibelt.us.com
    http://www.off-whiteshoes.us.com
    http://www.bape-hoodie.us.com
    http://www.nikefoamposite.us.com
    http://www.pandorabracelet.in.net
    http://www.outlettimberland.us.org
    http://www.kyrie4.org
    http://www.yeezyboost.com.co
    http://www.handbagsmichaelkors.com
    http://www.nike-roshe.us.com
    http://www.nikecortez.us.com
    http://www.goyard.us.com
    http://www.long-champhandbags.org.uk
    http://www.polosralphlaurenuk.com
    http://www.russellwestbrookshoes.us.com
    http://www.jordansshoes.us.org
    http://www.michael-korsoutlets.us
    http://www.shoesjordan.us.com
    http://www.yeezy700.us.com
    http://www.vans-outlet.us.com
    http://www.michael-kors-handbags.com.co
    http://www.goldengoose-sneakers.us
    http://www.lacostepolosshirts.com
    http://www.golden-goose.us.com
    http://www.kd-10.us
    http://www.longchamp-bags.us.org
    http://www.hermes-handbags.us.com
    http://www.yesyeezy.shop/supreme-x-nike-air-more-uptempo-varsity-redwhite-902290600-p-592.html
    http://www.hoganoutletonline.us.com
    http://www.nikepolo.us
    http://www.longchamphandbagsonlines.com
    http://www.retro-jordans.us.com
    http://www.curry5.us
    http://www.nikeairmax2018.us.com
    http://www.kobeshoes.uk
    http://www.michaelkors-outletstore.com
    http://www.nike-airmax2017.us.com
    http://www.asics-shoes.us.org
    http://www.adidasgazelle.us.com
    http://www.yeezy-boosts.us.com
    http://www.yeezyboost350v2.org.uk
    http://www.fila.us.org
    http://www.yesyeezy.shop/adidas-ultra-boost-c-82_89.html
    http://www.kobe-shoes.us.com
    http://www.lebron15.net
    http://www.hermesbelts.co.uk
    http://www.yesyeezy.shop/adidas-yeezy-boost-350-v2-beluga-solar-red-bb1826-p-422.html
    http://www.outletlacoste.us.com
    http://www.adidasshoesonline.com
    http://www.adidasstansmith.us.com
    http://www.adidasyeezys.us
    http://www.kobesneakers.com
    http://www.adidasyeezys.us.com
    http://www.jordan-retro.us.com
    http://www.goldengooseoutlet.us
    http://www.kyrieirving-shoes.us.com
    http://www.kobebasketballshoes.net
    http://www.fakerolex.us.com
    http://www.coachsonline.us.com
    http://www.coachoutletsfactory.com
    http://www.nikeairmax2019.us.com
    http://www.nikereact.org
    http://www.nikereact.us.com
    http://www.jordan12.us.com
    http://www.michaelkors-outletfactory.us.org
    http://www.vapormaxshoes.us
    http://www.jordan4.us.com
    http://www.offwhiteclothing.us.com
    http://www.birkinbag.us.com
    http://www.adidaseqts.com
    http://www.adidas-crazyexplosive.us.com
    http://www.yesyeezy.shop/adidas-yeezy-700-boost-wave-runner-b75571-p-428.html
    http://www.filas.us.com
    http://www.jordansforcheap.us.com
    http://www.yeezyboost-350.uk
    http://www.yesyeezy.shop/nike-air-max-197-sean-wotherspoon-aj4219400-p-66.html
    http://www.yeezy500.us
    http://www.outletmichael-kors.us.com
    http://www.nikeflyknit.us.com
    http://www.airmax270.us.com
    http://www.curry5.us.com
    http://www.adidas-pureboost.us.com
    http://www.curry4shoes.us.com
    http://www.valentinos.us.com
    http://www.cheapnbajerseyswholesales.us.com
    http://www.chromehearts.com.co
    http://www.bapehoodie.us
    http://www.nike-huarache.com
    http://www.adidasnmduk.com
    http://www.goldengoose-outlet.us.com
    http://www.coachoutlets.name
    http://www.offwhitexjordan1.com
    http://www.lebron16.net
    http://www.yesyeezy.shop/adidas-pharrell-williams-c-82_88.html
    http://www.yesyeezy.shop/offwhite-air-jordan-1-retro-chicago-the-ten-aa3834101-p-837.html
    http://www.yeezyboost350v2shoes.us.com
    http://www.adidasoutletonline.com
    http://www.yslhandbags.net
    http://www.yesyeezy.shop/offwhite-x-nike-air-presto-black-aa3830002-p-291.html
    http://www.air-max.us.com
    http://www.hermesonlineshop.com
    http://www.michaelkorsoutletonlineus.com
    http://www.outletonline-michaelkors.us.org
    http://www.yesyeezy.shop/balenciaga-17fw-triple-s-black-pink-women-sneaker-483523w06e38080-p-618.html
    http://www.michael--korsoutlet.us.org
    http://www.yesyeezy.shop/balenciaga-17fw-triple-s-trainer-black-red-mens-w05m23972-p-613.html
    http://www.jimmychoo-shoes.us.com
    http://www.reebokoutlet.us.org
    http://www.offwhitehoodie.us.com
    http://www.nikesneakers.us.com
    http://www.yeezy-shoes.us.org
    http://www.curry4.us.com
    http://www.adidasyeezy.co.uk
    http://www.monclersoutlet.us.com
    http://www.nfljerseys.us.org
    http://www.ferragamobelt.us
    http://www.fitflops-saleclearance.us.com
    http://www.adidassuperstar.us.com
    http://www.fila-shoes.us.com
    http://www.louboutinshoes.uk
  2. 김성희
    getMonth() 는 리턴값이 1부터가 아니라 0부터 11까지 입니다.
    대화보기
    • GNyon
      API를 천천히 훑어봐야겠네요 ㅎㅎ 잘듣고있습니다.
    • eh20
      자바와 자바스크립트는 인도와 인도네시아의 차이라는 말도..
    • Jamesmoon
      역시 제 상식선인지라...ㅎㅎ;; 0부터 11 항시 기억하겠습니다. 감사합니다~
      대화보기
      • egoing
        컴퓨터에서는 숫자가 0부터 카운팅이 됩니다. 숫자를 11로 하시면 Dec가 될꺼예요.
        대화보기
        • Jamesmoon
          date objcet 예제에서 질문입니다.

          var d1 = new Date(2002, 1, 18); <<--이부분의 1을 12로 바꿔서 실행해 보니
          결과값이 2002가 아닌 2003으로 나오는데 반올림인지 뭔지... 뭔가 이유가 있을까요?
          d2 객체도 마찬가지 결과구요...;; 12월은 다음 년도에 속한다고 판단하고 잇는걸까요?
          제 상식 선에서는 왜그런지 이해가 안되네요 ㅜㅜ
        • David Jun
          진짜 너무 대박, 초보 개발자로서 정말 너무 많이 도움이 되고 있어요. 감사해요^^
        • Sheva
          이골루야!
          (강의 너무 잘 보고 있습니다! 첫 댓글인데.. 너무 감사드립니다.)
        • earlycastle
          오오오 미쑵미다
          대화보기
          • WilliamHan
            강사느님께서는 무지한 저희들을 위하여 두가지 방법으로 기술 할 수 있다는 사실을 1라인을 더 코딩 하심으로써 몸소 보여주신 것입니다.
            대화보기
            • manorgass
              String object 예문에서
              var str = new String('egoing');var str = 'egoing';

              var str = new String();var str = 'egoing';//var str = new String('egoing');과 결과가 같다.
              라고 변경 해주시면 좋을 것 같습니다.
              var str = new String('egoing'); 에서 이미 str 은 egoing이라는 값을 가지고 있습니다.var str = 'egoing'; 를 삭제 하거나 내용을 변경하여 추가 설명으로 활용하는게 좋을 것 같습니다.
            버전 관리
            egoing
            현재 버전
            선택 버전
            graphittie 자세히 보기