質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.50%
Google API

Googleは多種多様なAPIを提供していて、その多くはウェブ開発者向けのAPIです。それらのAPIは消費者に人気なGoogleのサービス(Google Maps, Google Earth, AdSense, Adwords, Google Apps,YouTube等)に基づいています。

Ruby on Rails 4

Ruby on Rails4はRubyによって書かれたオープンソースのウェブフレームワークです。 Ruby on Railsは「設定より規約」の原則に従っており、効率的に作業を行うために再開発を行う必要をなくしてくれます。

Q&A

1回答

5191閲覧

Google Chrome コンソールエラーの解決方法をおしえてください

nk117

総合スコア31

Google API

Googleは多種多様なAPIを提供していて、その多くはウェブ開発者向けのAPIです。それらのAPIは消費者に人気なGoogleのサービス(Google Maps, Google Earth, AdSense, Adwords, Google Apps,YouTube等)に基づいています。

Ruby on Rails 4

Ruby on Rails4はRubyによって書かれたオープンソースのウェブフレームワークです。 Ruby on Railsは「設定より規約」の原則に従っており、効率的に作業を行うために再開発を行う必要をなくしてくれます。

0グッド

0クリップ

投稿2016/12/13 08:07

gmaps4railsを実装中に2つのエラーが発生しました。
分かる方がいれば解決方法を教えてください。

一つ目
google chrome console error
Uncaught ReferenceError: google is not defined(…)

(function() { this.Gmaps.Google.Primitives = function() { var factory; factory = { point: google.maps.Point, ← この列でエラーが出ています。 size: google.maps.Size, circle: google.maps.Circle, latLng: google.maps.LatLng, latLngBounds: google.maps.LatLngBounds, map: google.maps.Map, mapTypez: google.maps.MapTypeId, markerImage: google.maps.MarkerImage, marker: google.maps.Marker, infowindow: google.maps.InfoWindow, listener: google.maps.event.addListener, clusterer: MarkerClusterer, listenerOnce: google.maps.event.addListenerOnce, polyline: google.maps.Polyline, polygon: google.maps.Polygon, kml: google.maps.KmlLayer, addListener: function(object, event_name, fn) { return factory.listener(object, event_name, fn); }, addListenerOnce: function(object, event_name, fn) { return factory.listenerOnce(object, event_name, fn); }, mapTypes: function(type) { return factory.mapTypez[type]; }, latLngFromPosition: function(position) { if (_.isArray(position)) { return new factory.latLng(position[0], position[1]); } else { if (_.isNumber(position.lat) && _.isNumber(position.lng)) { return new factory.latLng(position.lat, position.lng); } else { if (_.isFunction(position.getServiceObject)) { return position.getServiceObject().getPosition(); } else { return position; } } } } }; return factory; }; }).call(this);

二つ目
GET http://localhost:3000/buildings/1/%E2%80%9Dhttps://maps.googleapis.com/maps/api/js?sensor=true&key=APIkey%E2%80%9C 404 (Not Found)
Failed to load resource: the server responded with a status of 404 (Not Found)

よろしくお願いします。

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

回答1

0

%E2%80%9Dと%E2%80%9Cはそれぞれダブルクォートですね。googlemapsapiのjsファイル自体が読めてないんじゃないでしょうか。どっかに全角ダブルクォート混ざってませんか?

投稿2018/02/20 07:37

perpouh

総合スコア299

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

まだベストアンサーが選ばれていません

会員登録して回答してみよう

アカウントをお持ちの方は

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.50%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問