当前位置:网站首页>“google is not defined” when using Google Maps V3 in Firefox remotely
“google is not defined” when using Google Maps V3 in Firefox remotely
2022-07-03 18:44:00 【fyin1314】
problem :
Here's my conundrum: I have a page that uses Google Maps V3 and jQuery. This is my problem : I have a use of Google Maps V3 and jQuery The page of .It all worked well locally in FF5, Chrome and Safari. It's all in FF5、Chrome and Safari Both are running well .
Once I uploaded to a web site, I get a "google is not defined" error on the first line that I try to use a google object After uploading to the website , I'm trying to use google The first line of the object receives “ Undefined google” error
var defaultLocation = new google.maps.LatLng(lat, lng);
It only occurs in FF and only occurs remotely (ie, if I load the file into FF locally, it works well). It only It happened in FF in also Only occurs remotely ( namely , If I load the file locally into FF in , It works well ).Chrome and Safari seem to be working great regardless, as is my Android and iPod browsers. in any case ,Chrome and Safari It seems to be working well , my Android and iPod The same goes for browsers .
Here's what I tried so far: This is what I have tried so far :
- Moved
<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>
to top of the<head>
section. take<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>
Moved to<head>
Top of section . - Moved all content of
$(function() {...});
Moved$(function() {...});
All contents$(function() {...});
to a function calledinitialize()
and added<body onload="initialize()">
To a place calledinitialize()
And add<body onload="initialize()">
- Played with scripts and css files order Use scripts and css Order of documents
- Pasted the URL http://maps.google.com/maps/api/js?sensor=false into FF address box and verified I'm getting the legit script take URL http://maps.google.com/maps/api/js?sensor=false Paste the FF In the address box and verify that I am getting a legal script
But since this is only happening in FF on a remote machine and works well otherwise, I don't think it has anything to do with my code. But because this is only on remote machines FF Occurs in and works well in other cases , I don't think this has anything to do with my code .Maybe the load order in FF5 is screwed. Maybe FF5 The loading sequence in is messed up .Maybe it prioritizes network resources differently than other browsers. Maybe its priority for network resources is different from that of other browsers .I really do not know what to make of it at this point. At this point , I really don't know what to do .
Any help is appreciated. To express appreciation for any help .
Guy guy
Update: to update :
Just wanted to add the following fact: After trying the previous on a Mac, I tried FF5 in Windows, and have replicated the exact same behavior. I just want to add the following facts : stay Mac After trying the previous one on , I am here Windows I tried FF5, And copied exactly the same behavior .
For good measure, I tried Pale Moon as well - same results. In order to better measure , I also tried Pale Moon - The result is the same .Chrome 14, Opera 11.50 and even frickin' IE9 (which wasn't included in the test plan) work.Chrome 14、Opera 11.50 Even damn IE9( Not included in the test plan ) Can work .It just FF5, now on both Mac and Windows 7, that fails on that page. It's just FF5, Now in Mac and Windows 7 All failed on this page .
Solution :
Reference resources : https://stackoom.com/en/question/Rwol边栏推荐
- 235. The nearest common ancestor of the binary search tree [LCA template + same search path]
- Recommend a simple browser tab
- 204. Count prime
- [combinatorics] generating function (example of using generating function to solve the number of solutions of indefinite equation)
- In addition to the prickles that pierce your skin, there are poems and distant places that originally haunt you in plain life
- Mysql45 lecture learning notes (II)
- [combinatorics] generating function (use generating function to solve the number of solutions of indefinite equation example 2 | extended to integer solution)
- Why can deeplab v3+ be a God? (the explanation of the paper includes super detailed notes + Chinese English comparison + pictures)
- Use of unsafe class
- 组策略中开机脚本与登录脚本所使用的用户身份
猜你喜欢
Summary and Reflection on the third week of winter vacation
How many convolution methods does deep learning have? (including drawings)
FBI 警告:有人利用 AI 换脸冒充他人身份进行远程面试
2022-2028 global aircraft head up display (HUD) industry research and trend analysis report
Know what it is, and know why, JS object creation and inheritance [summary and sorting]
虚拟机和开发板互Ping问题
2022-2028 global petroleum pipe joint industry research and trend analysis report
Torch learning notes (3) -- univariate linear regression model (self training)
Computer graduation design PHP campus address book telephone number inquiry system
Have you learned the correct expression posture of programmers on Valentine's day?
随机推荐
[combinatorics] exponential generating function (concept of exponential generating function | permutation number exponential generating function = combinatorial number ordinary generating function | e
In addition to the prickles that pierce your skin, there are poems and distant places that originally haunt you in plain life
[leetcode周赛]第300场——6110. 网格图中递增路径的数目-较难
CTO and programmer were both sentenced for losing control of the crawler
Torch learning notes (6) -- logistic regression model (self training)
Summary and Reflection on the third week of winter vacation
4. Load balancing and dynamic static separation
English語法_名詞 - 分類
Chisel tutorial - 06 Phased summary: implement an FIR filter (chisel implements 4-bit FIR filter and parameterized FIR filter)
Recent learning experience
Max of PHP FPM_ Some misunderstandings of children
leetcode:11. 盛最多水的容器【双指针 + 贪心 + 去除最短板】
webcodecs
NFT new opportunity, multimedia NFT aggregation platform okaleido will be launched soon
English grammar_ Noun classification
Raft 日志复制
What kind of experience is it when the Institute earns 20000 yuan a month?
my. INI file not found
Computer graduation project PHP library book borrowing management system
235. 二叉搜索树的最近公共祖先【lca模板 + 找路径相同】