diff --git a/application/index/view/default/public/header.html b/application/index/view/default/public/header.html index c115c54c8740b45d5f83607eff07274ae19e92bb..ca9e895cf103cd082e5f87ec0f617f457c512e99 100755 --- a/application/index/view/default/public/header.html +++ b/application/index/view/default/public/header.html @@ -50,6 +50,7 @@ var __default_theme__ = '{{$default_theme}}'; var __modal_login_url__ = '{{:Url("index/user/modallogininfo")}}'; var __attachment_host__ = '{{$attachment_host}}'; + var __seo_url_suffix__ = '{{:MyC("home_seo_url_html_suffix", "html", true)}}'; var __user_id__ = {{if empty($user['id'])}}0{{else /}}{{$user.id}}{{/if}}; diff --git a/application/plugins/petscms/Pets.php b/application/plugins/petscms/Pets.php index 3ab06068c0d8a916b47cc465bec9ff4b31c44960..339bc51bb20de5bda4079ce1db07a11fe0c89a73 100644 --- a/application/plugins/petscms/Pets.php +++ b/application/plugins/petscms/Pets.php @@ -265,7 +265,16 @@ class Pets extends Controller $this->assign('is_footer', 0); // 参数 - $this->assign('params', input()); + $params = input(); + if(!empty($params['lng'])) + { + $params['lng'] = base64_decode($params['lng']); + } + if(!empty($params['lat'])) + { + $params['lat'] = base64_decode($params['lat']); + } + $this->assign('params', $params); return $this->fetch('../../../plugins/view/petscms/pets/helpmap'); } } diff --git a/application/plugins/view/petscms/pets/helpmap.html b/application/plugins/view/petscms/pets/helpmap.html index 2e7d6633747db3cce8c4bbc94e8e4d68887f5f0d..e9e03d97649657e9317b735644d0a8c059e198c6 100644 --- a/application/plugins/view/petscms/pets/helpmap.html +++ b/application/plugins/view/petscms/pets/helpmap.html @@ -1,7 +1,7 @@ {{include file="public/header" /}} {{if !empty($params['lng']) and !empty($params['lat']) and $params['lng'] gt 0 and $params['lat'] gt 0}} -
+
{{else /}}
参数有误
{{/if}} @@ -17,7 +17,7 @@ { // 丢失地址-地图展示 var map = new BMap.Map("help-map", {enableMapClick:false}); - var level = $('#help-map').data('level') || 16; + var level = 17; var point = new BMap.Point({{$params['lng']}}, {{$params['lat']}}); map.centerAndZoom(point, level); diff --git a/public/static/plugins/css/petscms/pets.css b/public/static/plugins/css/petscms/pets.css index ea8474586fbb2fc05309ac84aeb068c960b1d14a..3df5ea7bbce76a21a528ea0f128a348bc2cb5065 100644 --- a/public/static/plugins/css/petscms/pets.css +++ b/public/static/plugins/css/petscms/pets.css @@ -73,6 +73,7 @@ form.form-validation #map { /** * 帮助页面 */ -.pets-help #help-map { - height: 80vh; +#help-map { + width: 100%; + height: 100vh; } \ No newline at end of file diff --git a/public/static/plugins/js/petscms/pets.js b/public/static/plugins/js/petscms/pets.js index 5097645b57f3c5f104ca11c4c62693c01452b863..dede4f04932c36887dca8d3b8050a73fefb88140 100644 --- a/public/static/plugins/js/petscms/pets.js +++ b/public/static/plugins/js/petscms/pets.js @@ -7,7 +7,8 @@ $(function() var lat = parseFloat($(this).data('lat')); if(lng > 0 && lat > 0) { - var url = UrlFieldReplace('lat', lat, UrlFieldReplace('lng', lng, $('.pets-help').data('url'))); + // 数据base64避免特殊字符 + var url = UrlFieldReplace('lat', window.btoa(lat), UrlFieldReplace('lng', window.btoa(lng), $('.pets-help').data('url'))); ModalLoad(url, '地图', 'plugins-petscms-popup-modal-help'); } });