본문 바로가기

Web/자바스크립트

(7)
카카오책 검색기능 구현(API 개념활용) 1. jQuery CDN --> jQuery Core 아래 uncomprssed클릭한 후 코드복사 -->vs code>index.html -->태그 바로 위에 붙여넣기. 2. jQuery Ajax 검색---> jQuery.Ajax()를 이용한 함수들 중에서 example을 찾아서 코드를 카피 --> 자바스크립트를 작성할 것이기에 바디태그안쪽 script 태그를 만들어 붙여넣기 3. API 가이드 ---> 카카오 개발자 로그인 --> 앱만들기 클릭 --> API키 발급 --> 개발가이드 -->검색 --> REST API개발가이드 ---> 책검색 ---> request / response 에 대한 정보 참고 ---> 키를 넣어줄때 headers인지 확인( Headers라고 입력하면 오류 뿡뿡 ㅠㅠ ) -->..
칸아카데미>>SQL>>gradebook CREATE TABLE student_grades ( id INTEGER PRIMARY KEY AUTOINCREMENT, name TEXT, number_grade INTEGER, fraction_completed REAL); INSERT INTO student_grades (name, number_grade, fraction_completed) VALUES ("Winston", 90, 0.805);INSERT INTO student_grades (name, number_grade, fraction_completed) VALUES ("Winnefer", 95, 0.901);INSERT INTO student_grades (name, number_grade, fraction_completed) VALUES..
칸아카데미>>SQL>>CASE Calculating results with CASE CREATE TABLE exercise_logs (id INTEGER PRIMARY KEY AUTOINCREMENT, type TEXT, minutes INTEGER, calories INTEGER, heart_rate INTEGER); INSERT INTO exercise_logs(type, minutes, calories, heart_rate) VALUES ("biking", 30, 100, 110);INSERT INTO exercise_logs(type, minutes, calories, heart_rate) VALUES ("biking", 10, 30, 105);INSERT INTO exercise_logs(type, minutes, calor..
sql CREATE TABLE books ( id INTEGER PRIMARY KEY AUTOINCREMENT, author TEXT, title TEXT, words INTEGER); INSERT INTO books (author, title, words) VALUES ("J.K. Rowling", "Harry Potter and the Philosopher's Stone", 79944); INSERT INTO books (author, title, words) VALUES ("J.K. Rowling", "Harry Potter and the Chamber of Secrets", 85141); INSERT INTO books (author, title, words) VALUES ("J.K. Rowling", ..
자바스크립트_객체지향_object 1#var arr = {'name': 'jason', 'age': 20, 'city': 'Seoul' }; Object.keys(arr) ["name", "age", "city"] arr.name "jason" arr.age //20 arr.city //"Seoul" arr.toS //undefined arr.toString toString() { [native code] } 2#var arr = {'name': 'jason', 'age': 20, 'city': 'Seoul' }; arr Object {name: "jason", age: 20, city: "Seoul"} Object.keys(arr) ["name", "age", "city"] 3#var arr = [10,20,30] arr.toStrin..
자바스크립트_this 객체란 서로 연관된 변수와 함수를 그룹핑한 그릇이라고 할 수 있다. 객체 내의 변수를 프로퍼티(property), 함수를 메소드(method)라고 부른다. 객체를 만들어보자. 1# var person = {}; // var Person = new person(); 와 같은 효과이다. 즉 person이 객체person.name = 'jasonkim';person.introduce= function(){ return this.name; // this 는 객체인 person 이다.} console.log(this.name); person.introduce() //"jasonkim" 2# var person = {}; // var Person = new person(); 와 같은 효과이다. 즉 person이 객..
자바스크립트_Node객체 [JavaScript] Node 객체Node 객체1. 소개Node 객체는 DOM에서 시조와 같은 역할을 한다. 다시 말해서 모든 DOM 객체는 Node 객체를 상속 받는다. Node 객체의 위상을 그림으로 나타내면 아래와 같다. 모든 엘리먼트, 텍스트, 주석등 HTML코드의 모든 문서의 구성요소들의 객체는 공통적으로 Node라는 객체를 상속받는다.Node객체는 firstChild, lastChild, nextSibling등의 프로퍼티를 가지고 있어서 이를 이용해서 각각의 Node들을 기준으로해서 자식이 누구인지, 형제가 누구인지 알 수 있다.2. 주요기능Node 객체의 주요한 임무는 아래와 같다.(1) 관계엘리먼트는 서로 부모, 자식, 혹은 형제자매 관계로 연결되어 있다. 각각의 Node가 다른 Node..