{"id":6949,"date":"2019-03-13T10:00:17","date_gmt":"2019-03-13T01:00:17","guid":{"rendered":"https:\/\/www.gigas-jp.com\/appnews\/?p=6949"},"modified":"2019-03-13T10:21:18","modified_gmt":"2019-03-13T01:21:18","slug":"%e6%96%b0%e4%ba%ba%e6%97%a5%e8%aa%8c7","status":"publish","type":"post","link":"https:\/\/www.gigas-jp.com\/appnews\/archives\/6949","title":{"rendered":"\u65b0\u4eba\u65e5\u8a8c7"},"content":{"rendered":"\n<p>Web\u30d6\u30e9\u30a6\u30b6\u4e0a\u3067\u3001Google map\u95a2\u9023API\u306e<\/p>\n\n\n\n<p>google.maps.places.Autocomplete\u3000\u3092\u4f7f\u3063\u3066\u3001<\/p>\n\n\n\n<p>\u691c\u7d22\u5019\u88dc\u306e\u81ea\u52d5\u5165\u529b\u3092\u8ffd\u52a0\u3057\u3066\u3001\u5834\u6240\u691c\u7d22\u3092\u4fbf\u5229\u306b\u3057\u3066\u307f\u307e\u3059\u3002<\/p>\n\n\n<p><!--more--><\/p>\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" width=\"480\" height=\"483\" src=\"\/appnews\/wp-content\/uploads\/sites\/4\/2019\/03\/9078f9363cbe062780d805ba31611b47.png\" alt=\"\" class=\"wp-image-6952\"\/><\/figure>\n\n\n\n<p>Autocomplete\u306e\u4f7f\u3044\u65b9\u306f\u3068\u3066\u3082\u7c21\u5358\u3067\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>var [\u4efb\u610f\u306e\u5909\u6570]= new google.maps.places.Autocomplete(inputtext, options);<\/code><\/pre>\n\n\n\n<p>\u3067\u4f5c\u6210\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u4e00\u3064\u76ee\u306e\u5f15\u6570inputtext\u306b\u306f<\/p>\n\n\n\n<p>\u30e6\u30fc\u30b6\u30fc\u304c\u5165\u529b\u3057\u3001\u30aa\u30fc\u30c8\u30b3\u30f3\u30d7\u30ea\u30fc\u30c8\u306e\u7d50\u679c\u3092\u53d7\u3051\u53d6\u308binput\u8981\u7d20\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u4e8c\u3064\u3081\u306e\u5f15\u6570options\u306b\u306f<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>var options = {\n      \/\/\u5019\u88dc\u3068\u3057\u3066\u307b\u3057\u3044\u5834\u6240\u60c5\u5831type\u3092\u6307\u5b9a\n      types: ['establishment'], \n      \/\/\u512a\u5148\u3057\u3066\u691c\u7d22\u3059\u308b\u7bc4\u56f2\u3092\u6307\u5b9a\n      bounds: bounds,           \n      \/\/\u56fd\u3001\u5730\u57df\u3092\u9650\u5b9a\u3057\u305f\u3044\u5834\u5408\u306b\u6307\u5b9a\u3059\u308b\n      componentRestrictions: {country: 'ja'}  \n    }<\/code><\/pre>\n\n\n\n<p>\u3068\u3044\u3063\u305f\u5019\u88dc\u3092\u7d5e\u308b\u305f\u3081\u306e\u60c5\u5831\u3092\u4f5c\u6210\u3057\u3001<\/p>\n\n\n\n<p>\u3053\u308c\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>\u57fa\u672c\u7684\u306b\u306f\u3053\u308c\u3060\u3051\u3067\u4f7f\u3048\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u3067\u3059\u304c\u3001iOS\u306e\u30d6\u30e9\u30a6\u30b6\u3067\u306f\u3082\u3046\u3059\u3053\u3057\u51e6\u7406\u3092\u8ffd\u52a0\u3057\u306a\u3044\u3068\u3001<\/p>\n\n\n\n<p>\u9078\u3093\u3060\u30b5\u30b8\u30a7\u30b9\u30c8\u5019\u88dc\u304cinput\u30c6\u30ad\u30b9\u30c8\u8981\u7d20\u306b\u53cd\u6620\u3055\u308c\u307e\u305b\u3093\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\/\/iOS\u30c7\u30d0\u30a4\u30b9\u306a\u3089\n    if (navigator.userAgent.match(\/(iPad|iPhone|iPod)\/g)) {\n      \/\/500\u30df\u30ea\u79d2\u5f8c\u306b\n      setTimeout(function () {\n        \/\/pac-container\u3067'touchend'\u3067\u30d0\u30d6\u30ea\u30f3\u30b0\u3057\u306a\u3044\u3088\u3046\u306b\n        var container = document.getElementsByClassName('pac-container')[0];\n        container.addEventListener('touchend', function (e) {\n          e.stopImmediatePropagation();\n        });\n      }, 500);\n    }<\/code><\/pre>\n\n\n\n<p>\u3053\u308c\u3067iOS\u3067\u3082<\/p>\n\n\n\n<p>google.maps.places.Autocomplete<\/p>\n\n\n\n<p>\u304c\u4f7f\u3048\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u53c2\u8003\u8a18\u4e8b<\/p>\n\n\n\n<p><a href=\"https:\/\/developers.google.com\/maps\/documentation\/javascript\/places-autocomplete\">https:\/\/developers.google.com\/maps\/documentation\/javascript\/places-autocomplete<\/a><\/p>\n\n\n\n<p><a href=\"https:\/\/gist.github.com\/schoenobates\/ef578a02ac8ab6726487\">https:\/\/gist.github.com\/schoenobates\/ef578a02ac8ab6726487<\/a><\/p>\n\n\n\n<p>\u6c34\u66dc\u62c5\u5f53:Tanaka<\/p>\n<div class='wp_social_bookmarking_light'>\n            <div class=\"wsbl_google_plus_one\"><g:plusone size=\"medium\" annotation=\"none\" href=\"https:\/\/www.gigas-jp.com\/appnews\/archives\/6949\" ><\/g:plusone><\/div>\n            <div class=\"wsbl_hatena_button\"><a href=\"\/\/b.hatena.ne.jp\/entry\/https:\/\/www.gigas-jp.com\/appnews\/archives\/6949\" class=\"hatena-bookmark-button\" data-hatena-bookmark-title=\"\u65b0\u4eba\u65e5\u8a8c7\" data-hatena-bookmark-layout=\"standard\" title=\"\u3053\u306e\u30a8\u30f3\u30c8\u30ea\u30fc\u3092\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306b\u8ffd\u52a0\"> <img src=\"\/\/b.hatena.ne.jp\/images\/entry-button\/button-only@2x.png\" alt=\"\u3053\u306e\u30a8\u30f3\u30c8\u30ea\u30fc\u3092\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306b\u8ffd\u52a0\" width=\"20\" height=\"20\" style=\"border: none;\" \/><\/a><script type=\"text\/javascript\" src=\"\/\/b.hatena.ne.jp\/js\/bookmark_button.js\" charset=\"utf-8\" async=\"async\"><\/script><\/div>\n            <div class=\"wsbl_twitter\"><a href=\"https:\/\/twitter.com\/share\" class=\"twitter-share-button\" data-url=\"https:\/\/www.gigas-jp.com\/appnews\/archives\/6949\" data-text=\"\u65b0\u4eba\u65e5\u8a8c7\" data-via=\"GIGASJAPAN_APPS\" data-lang=\"ja\">Tweet<\/a><\/div>\n            <div class=\"wsbl_facebook_like\"><div id=\"fb-root\"><\/div><fb:like href=\"https:\/\/www.gigas-jp.com\/appnews\/archives\/6949\" layout=\"button_count\" action=\"like\" width=\"100\" share=\"false\" show_faces=\"false\" ><\/fb:like><\/div>\n            <div class=\"wsbl_facebook_send\"><div id=\"fb-root\"><\/div><fb:send href=\"https:\/\/www.gigas-jp.com\/appnews\/archives\/6949\" colorscheme=\"light\" ><\/fb:send><\/div>\n    <\/div>\n<br class='wp_social_bookmarking_light_clear' \/>\n","protected":false},"excerpt":{"rendered":"<p>Web\u30d6\u30e9\u30a6\u30b6\u4e0a\u3067\u3001Google map\u95a2\u9023API\u306e google.maps.places.Autocomplete\u3000\u3092\u4f7f\u3063\u3066\u3001 \u691c\u7d22\u5019\u88dc\u306e\u81ea\u52d5\u5165\u529b\u3092\u8ffd\u52a0\u3057\u3066\u3001\u5834\u6240\u691c\u7d22\u3092\u4fbf\u5229\u306b\u3057\u3066\u307f\u307e\u3059\u3002<\/p>\n","protected":false},"author":17,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[27],"tags":[],"acf":[],"_links":{"self":[{"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/posts\/6949"}],"collection":[{"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/users\/17"}],"replies":[{"embeddable":true,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/comments?post=6949"}],"version-history":[{"count":8,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/posts\/6949\/revisions"}],"predecessor-version":[{"id":6961,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/posts\/6949\/revisions\/6961"}],"wp:attachment":[{"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/media?parent=6949"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/categories?post=6949"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/tags?post=6949"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}