Google maps 地图中的单个位置标记加载太慢
这是我的链接-。2-3分钟后加载一些位置标记。我正在使用这些文件jquery-activmap.js、markercluster.js、jquery-activmap.css。 我找不到问题所在。请任何人给我解决方案 这是我的密码Google maps 地图中的单个位置标记加载太慢,google-maps,google-maps-api-3,Google Maps,Google Maps Api 3,这是我的链接-。2-3分钟后加载一些位置标记。我正在使用这些文件jquery-activmap.js、markercluster.js、jquery-activmap.css。 我找不到问题所在。请任何人给我解决方案 这是我的密码 <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta name="viewport" content="width=device-
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta property="og:url" content="http://wesharenotes.com/maps" />
<meta property="og:type" content="article" />
<meta property="og:title" content="Add your blog to our map!" />
<meta property="og:description" content="We are a friendly community!" />
<meta property="og:image" content="http://wesharenotes.com/app/webroot/assets/maps/images/bmap.png" />
<link rel="stylesheet" href="assets/css/bootstrap.min.css">
<link rel="stylesheet" href="assets/css/jquery-activmap.css">
<!-- Fonts -->
<link rel="stylesheet" href="http://fonts.googleapis.com/css?family=Open+Sans:400,300,600">
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css">
<!-- JQuery -->
<script src="http://code.jquery.com/jquery-1.10.2.min.js"></script>
<!-- Bootstrap 3 -->
<script src="assets/js/bootstrap.min.js"></script>
<!-- Google Maps API V3 -->
<script src="https://maps.googleapis.com/maps/api/js?v=3.exp&libraries=places"></script>
<!-- WeShareNotes plugin -->
<script src="assets/js/jquery-activmap.js"></script>
<script src="assets/js/markercluster.js"></script>
<script>
$(function() {
$.ajax({
url: "assets/maps/places.json",
type: "POST",
dataType: "json",
success: function(data) {
response = data;
$('#activmap-wrapper').activmap({
places: response.places,
icon: 'assets/maps/images/marker.png',
posPanel: 'left',
showPanel: false,
radius: 0, //18
cluster: true,
zoom: 0, //6
autogeolocate: false,
});
}
});
});
</script>
</head>
<body>
<!-- Email subscription modal-->
<div class="modal fade subscription-dialog" id="subscriptionModal" tabindex="-1" role="dialog">
<div class="modal-dialog " role="document">
<div class="modal-content subscription-content">
<div class="modal-body">
<form id="emailSubscriptionData" action="" method="post">
<div class="form-group">
<p style="text-align:center"><img src="http://wesharenotes.com/app/webroot/assets/images/panda.gif" /></p>
<h3 class="signup-wrap">New!! Map of Bloggers from Earth</h3>
<label for="message-text" class="control-label" style="color:#d2851e;">Want more visitors on your blog? Add your blog to the map and Share with your blogger friends. </label>
</div>
</form>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">I understand</button>
<!-- <button type="button" class="btn btn-success Submitbutton" id="subscribeBtn">Proceed to Map</button>-->
</div>
<div class="signup-smallprint">Based on ZipCodes, not precise locations.</div>
</div>
</div>
</div>
<div class="container-fluid">
<div class="row">
<div class="col-md-3">
<a href="http://wesharenotes.com" target="_blank" title="HomePage"><img src="assets/maps/images/logo.png"></a>
<div class="form-group">
</div>
<a class="btn btn-default2" href="http://wesharenotes.com/users/register" style="background-color:#e94a3a;margin-bottom:10px;"><i class="fa fa-crosshairs"></i> Add your blog to the Map</a>
<div class="panel-group" id="activmap-accordion">
<div class="panel panel-default">
<div class="panel-heading">
<h4 class="panel-title">
<a data-toggle="collapse" href="#collapse-services">
<i class="fa fa-list"></i> Categories
</a>
</h4>
</div>
<div id="collapse-services" class="panel-collapse collapse in">
<div class="panel-body">
<input type="checkbox" name="marker_type[]" value="1" checked> Bloggers
<br>
<input type="checkbox" name="marker_type[]" value="2" checked> Creatives
<br>
</div>
</div>
</div>
<style type="text/css">
ul.share-buttons {
list-style: none;
padding: 0;
}
ul.share-buttons li {
display: inline;
}
ul.share-buttons img {
width: 52px;
filter: grayscale(60%);
}
ul.share-buttons img:hover {
width: 52px;
filter: grayscale(0%);
}
.subscription-content {
background: rgba(255, 255, 255, .8);
color: #536271;
padding: 20px;
max-width: 580px;
margin: 30px auto;
border-radius: 5px;
box-shadow: 0 2px 5px 0 rgba
}
.subscription-dialog {
color: #536271;
position: absolute;
margin-left: auto;
margin-top: auto;
background-color: rgba(66, 139, 202, 0.78);
z-index: 11;
}
.signup-wrap h3 {
font-size: 1.6rem;
font-weight: 600;
text-transform: uppercase;
text-align: center;
margin: .5rem;
font-family: proxima-nova, sans-serif;
}
.signup-smallprint {
font-size: 1.2rem;
font-style: italic;
text-align: center;
opacity: .8;
}
.label {
display: block;
padding-left: 15px;
text-indent: -15px;
}
.input {
width: 13px;
height: 13px;
padding: 0;
margin: 0;
vertical-align: bottom;
position: relative;
top: -1px;
*overflow: hidden;
}
.sign-up-cta {
margin: 0 auto;
border: 1px solid #f0f0f0;
text-align: center;
overflow: hidden;
margin-top: 1em;
border-radius: 5px;
z-index: 10;
max-width: 120em;
width: 100%;
margin-top: 1em;
margin-bottom: 1em;
background-color: #fff;
position: relative;
-webkit-transition: bottom 1s;
transition: bottom 1s
}
.modal-footer {
padding-top: 0;
}
</style>
<p style="transition: font-size 20s ease-in-out;font-size:1.5em;">Share:</p>
<ul class="share-buttons">
<li>
<a href="http://www.facebook.com/share.php?u=http://wesharenotes.com/maps" title="Share on Facebook" target="_blank">
<img src="http://wesharenotes.com/app/webroot/assets/images/Facebook.svg" />
</a>
</li>
<li>
<a href="https://twitter.com/intent/tweet?source=http%3A%2F%2Fwesharenotes.com/maps&text=Map%20of%20Bloggers%20Near%20You:%20http%3A%2F%2Fwesharenotes.com/maps&via=wesharenotes" target="_blank" title="Tweet"><img src="http://wesharenotes.com/app/webroot/assets/images/Twitter.svg"></a>
</li>
<li>
<a href="http://www.linkedin.com/shareArticle?mini=true&url=http%3A%2F%2Fwesharenotes.com/maps&title=Map%20of%20Bloggers%20Near%20You&summary=&source=http%3A%2F%2Fwesharenotes.com/maps" target="_blank" title="Share on LinkedIn"><img src="http://wesharenotes.com/app/webroot/assets/images/LinkedIn.svg"></a>
</li>
</ul>
</div>
</div>
<div class="col-md-9">
<div id="activmap-wrapper">
<!-- Places panel (auto removable) -->
<div id="activmap-places" class="hidden-xs">
<div id="activmap-results-num"></div>
</div>
<!-- Map wrapper -->
<div id="activmap-canvas"></div>
</div>
</div>
</div>
</div>
<script>
$(document).ready(function() {
var userID = '<?php echo $this->Session->read('
Auth.User.id ');?>';
if (!userID) {
$('#subscriptionModal').modal({
backdrop: 'static',
keyboard: false
});
$('#subscriptionModal').modal('show');
$('.modal-backdrop.in').hide();
$("#subscribeBtn").click(function() {
var email = $('#email_subscription').val();
if (isEmail(email)) {
$.ajax({
url: "/maps/bloggers_sbuscribe/",
data: $('#emailSubscriptionData').serialize(),
type: "POST",
dataType: "json",
success: function(e) {
$('#subscriptionModal').modal('hide');
}
});
} else {
$('#subscribe_error').html('Please enter a valid email');
return false;
}
});
}
});
function isEmail(email) {
var regex = /^([a-zA-Z0-9_.+-])+\@(([a-zA-Z0-9-])+\.)+([a-zA-Z0-9]{2,4})+$/;
return regex.test(email);
}
</script>
</body>
</html>
$(函数(){
$.ajax({
url:“assets/maps/places.json”,
类型:“POST”,
数据类型:“json”,
成功:功能(数据){
响应=数据;
$(“#activmap包装器”).activmap({
地点:response.places,
图标:“assets/maps/images/marker.png”,
posPanel:'左',
显示面板:错误,
半径:0,//18
集群:对,
缩放:0,//6
自动地理定位:false,
});
}
});
});
新的!!地球博主地图
想要在你的博客上有更多的访客吗?将您的博客添加到地图,并与您的博客好友共享。
我理解
基于Zipcode,而不是精确的位置。
博主
创造性的
共享按钮{
列表样式:无;
填充:0;
}
ul.share-li{
显示:内联;
}
共享按钮img{
宽度:52px;
滤镜:灰度(60%);
}
ul.共享按钮img:悬停{
宽度:52px;
滤镜:灰度(0%);
}
.订阅内容{
背景:rgba(255,255,255,8);
颜色:#536271;
填充:20px;
最大宽度:580像素;
保证金:30像素自动;
边界半径:5px;
长方体阴影:0 2px 5px 0 rgba
}
.订阅对话框{
颜色:#536271;
位置:绝对位置;
左边距:自动;
页边顶部:自动;
背景色:rgba(66,139,202,0.78);
z指数:11;
}
.注册包装h3{
字体大小:1.6rem;
字号:600;
文本转换:大写;
文本对齐:居中;
保证金:5雷姆;
字体系列:proxima nova,无衬线;
}
.注册smallprint{
字号:1.2rem;
字体:斜体;
文本对齐:居中;
不透明度:.8;
}
.标签{
显示:块;
左侧填充:15px;
文本缩进:-15px;
}
.输入{
宽度:13px;
高度:13px;
填充:0;
保证金:0;
垂直对齐:底部对齐;
位置:相对位置;
顶部:-1px;
*溢出:隐藏;
}
.注册cta{
保证金:0自动;
边框:1px实心#f0;
文本对齐:居中;
溢出:隐藏;
边缘顶部:1米;
边界半径:5px;
z指数:10;
最大宽度:120em;
宽度:100%;
边缘顶部:1米;
边缘底部:1米;
背景色:#fff;
位置:相对位置;
-webkit转换:底部1s;
转换:底部1秒
}
.模态页脚{
填充顶部:0;
}
共享:
-
-
-
$(文档).ready(函数(){
var userID='';
如果(!userID){
$('#subscriptionmodel').model({
背景:“静态”,
键盘:错误
});
$('#subscriptionmodel').model('show');
$('.modal background.in')。隐藏(