lab.naminsik
  • Javascript, jQuery
  • Reactjs
  • React Native
  • iOS
  • Android
  • AWS
  • Server
  • Html, CSS
  • Php
  • asp .net
  • SQL
  • Word Press
search
keywords
  • WP Tip & Tech 2017‧08‧02

    wp-json 으로 json 호출시 썸네일과 커스텀 필드 받기

    사용자 입력 필드나 썸네일 url을 얻어내기 위한 코드이다. 테마의 function.php에 추가한다. add_filter('rest_prepare_post', 'append_acf'); function append_acf($response) { $thumbnail_id = get_post_thumbnail_id( $post->ID ); $thumbnail = wp_get_attachment_image_src( $thumbnail_id ); $_data['featured_image_thumbnail_url'] = $thumbnail[0]; $response->data['acf'] = get_fields($response->data['id']); $response->data['thumbnail'] = $thumbnail[0]; return $response; };  

  • Javascript, jQuery 2015‧01‧26

    jQuery - Ajax로 데이터 불러오기

    외부 데이터를 불러올 때 Ajax를 통해서 가져오는 경우가 많다. Ajax를 통해서 Json 형식의 파일을 불러오는 예제를 만들면 아래와 같다. $.ajax({ type: "GET", url: "파일경로및 파일명", dataType: "json", cache: false, success: function(data){ $.each(data.dataList,function(index){ $('li').eq(index).html(data.dataList[index].val); }); },error: function(XMLHttpRequest, textStatus, errorThrown) { console.log("Status: " + textStatus); },timeout: 3000 });  설명하자면 timeout 에 3000을 입력해둔 것은 외부 데이터를 불러오는 […]

popular

  • jQuery - a 태그의 href 값 변경하기
  • [회고] Github Actions가 갑자기 안된다. (Waiting for a runner to pick up this job…)
  • 크롬 브라우저 http 웹사이트에서 위치(지오로케이션) 가져오기 중단
  • ul과 ol에 있는 li태그에서 들여쓰기 및 앞표시 없애기
  • 페이스북 공유시 나오는 정보 수정 방법
  • Github 계정 정지 당함 (account suspended)
  • 게시판 플러그인 KBoard 설치법 및 사용법
  • CodeDeploy agent was not able to receive the lifecycle event. Check the CodeDeploy agent logs on your host and make sure the agent is running and can connect to the CodeDeploy server.
  • 플래시 플레이어 버전 확인 및 디버거 다운로드
  • css - 크롬 position fixed 버그 해결 방법

comment

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