lab.naminsik
  • Javascript, jQuery
  • Reactjs
  • React Native
  • iOS
  • Android
  • AWS
  • Server
  • Html, CSS
  • Php
  • asp .net
  • SQL
  • Word Press
search
keywords
  • Javascript, jQuery 2015‧02‧12

    jQuery 플러그인 - 크로스 도메인 ajax로 가져오기

    외부에서 파일을 가져올 때 도메인이 다르면 보안 정책에 의해서 파일이 불러와지지 않는다. 이를 도와주는 플러그인이 있다. Cross-domain requests with jQuery 소개 및 다운로드 주소는 http://james.padolsey.com/javascript/cross-domain-requests-with-jquery/ 이다. 사용 방법은 간단하다. 일반적으로 ajax 호출하는 것은 그대로 사용하고 head안에 플러그인을 불러오기만 하면 된다. <script type="text/javascript" src="./js/jquery.xdomainajax.js"></script>  

  • Angularjs 2015‧02‧12

    Angularjs - 외부 json 파일 불러와서 dom에 바인딩 시키기

    코드 출처 : http://codepen.io/tutorialab/pen/EJAet?editors=101 <div id="wrapper" ng-app> <div ng-controller="DataCtrl"> <pre ng-model="data"> {{data}} </pre> <input ng-model='name' /> {{name}} <input ng-model='salutation' /> {{salutation}} <input ng-model='greeting' /> {{greeting}} </div> </div>  위 처럼 html 을 만든다. angular.module('', []); function DataCtrl($scope, $http) { $http.jsonp("http://angularjs.org/greet.php?callback=JSON_CALLBACK&name=Super%20Hero"). success(function(data) { $scope.data = data; $scope.name = data.name; $scope.salutation = data.salutation; $scope.greeting = data.greeting; }). error(function (data) […]

  • Angularjs 2015‧02‧12

    Angularjs - jsonp 불러오기

    외부에 있는 json 파일을 불러오는 코드이다. 출처 : http://jsfiddle.net/zkfruxu3/ <div ng-app ng-controller="jsonp_example"> <button ng-click="doRequest()">Make JSONP request</button> </div>  위 처럼 html 안에 버튼을 클릭하면 doRequest 함수가 실행되게 만든다. function jsonp_example($scope, $http) { $scope.doRequest = function() { var url = "http://public-api.wordpress.com/rest/v1/sites/wtmpeachtest.wordpress.com/posts?callback=JSON_CALLBACK"; $http.jsonp(url) .success(function(data){ console.log(data.found); }); }; var url = "http://public-api.wordpress.com/rest/v1/sites/wtmpeachtest.wordpress.com/posts?callback=JSON_CALLBACK"; $http.jsonp(url) .success(function(data){ console.log(data.found); }); }  외부 파일을 $http.jsonp을 통해 […]

  • Php 2014‧01‧21

    Php - include(), require(), include_once(), require_once()

    외부 파일을 현재 페이지에 삽입하고자 할 때 사용한다.크게보면 두가지로 include와 require 이다.이 두개의 차이점은 삽입하려는 외부 파일이 없을 때 삽입 코드 후에 어떠한 결과를 보여주는지에 따라 다르다. include <?php include('contents.php'); ?> 삽입하려는 외부 파일이 없을 경우에는 아래 화면 우측처럼 누락시킨 후에 다음 코드를 진행한다. require <?php require('contents.php'); ?> 삽입하려는 외부 파일이 없을 경우에는 아래 화면 […]

popular

  • 풀사이즈 배경으로 동영상 or 이미지 삽입하기
  • [회고] Github Actions가 갑자기 안된다. (Waiting for a runner to pick up this job…)
  • jQuery - a 태그의 href 값 변경하기
  • php- 날짜 비교 개월 수로 표현하기
  • JS - datepicker(jQueryUI,달력) 이용시 두개 날짜 범위 설정
  • 동영상 스트리밍 서비스 구축 (AWS s3/cloudFront, HLS, video.js)
  • 로고디자인 - 블랙과 화이트 색상을 이용한 심플한 로고 디자인 모음
  • map 역순으로 처리 (배열 역순)
  • 창 사이즈 읽어오기 scrollHeight / clientHeight / scrollTop (브라우즈별 차이점)
  • 글 쓰기 편한 에디터 TinyMCE Advanced

comment

  • 감사합니다!
  • 감사합니다~
  • 잘 해결 되셨다니 다행입니다!...
  • 정말 감사합니다. 덕분에 해결했습니다!...
  • 유용한정보 대단히 감사합니다....