diff --git a/info.xml b/info.xml
index ba1f8a3..5970523 100644
--- a/info.xml
+++ b/info.xml
@@ -4,22 +4,25 @@
Maps
지도를 원하는 곳에 추가하거나 수정할 수 있습니다. Google Maps API, 다음 지도 API, 다음 로컬 API 등이 사용되었습니다.
Maps can be inserted in your documents. Google Maps API, Daum Maps API, Daum Local API and some other APIs are included.
- 1.1.4
- 2015-07-05
+ 1.1.5
+ 2015-07-12
GPLv3
-
+
김민수(misol)
MinSoo Kim(misol)
- 다음 API REST/JS Key
+ 다음 API REST/JS Key(선택)
+ DaumKakao API REST/JS Key(Optional, For Korean maps)
https://developers.daum.net/console 에서 앱 만들기 후, API 키 메뉴에서 REST/JS API 키 항목을 통해 웹 브라우저용 API 키를 발급 받으신 키를 입력해주세요.
- 지도 API Key
+ 지도 API Key(선택)
+ Maps API Key(Optional, For Korean maps)
https://developers.daum.net/console 에서 앱 만들기 후, API 키 메뉴에서 REST/JS API 키 항목을 통해 웹 브라우저용 API 키를 발급 받으시거나, https://developer.naver.com/openapi/register.nhn 에서 지도 API 키를 발급받은 후 입력해주세요.
- 다음 지도를 이용하실 경우, 위 다음 API REST/JS Key에서 입력한 키와 동일한 키를 입력하셔야 다음 지도를 이용하실 수 있습니다.
+ 다음 지도를 이용하실 경우, 위 다음 API REST/JS Key에서 입력한 키와 동일한 키를 입력하셔야 다음 지도를 이용하실 수 있습니다.
+ 아무 값을 입력하지 않을 경우, 구글 지도가 나타납니다.
\ No newline at end of file
diff --git a/map_components.class.php b/map_components.class.php
index d9773cf..f4731ba 100644
--- a/map_components.class.php
+++ b/map_components.class.php
@@ -70,7 +70,7 @@ function decode_data() {
if($height_style[2]) $height = intval(trim($height_style[2]));
if(!$height) $height = intval($xml_obj->attrs->height);
- if(!$height) {$height = 400;}
+ if(!$height) {$height = 300;}
$this->add("width", $width);
$this->add("height", $height);
@@ -318,7 +318,7 @@ function transHTML($xml_obj) {
if($height_style[2]) $height = intval(trim($height_style[2]));
if(!$height) $height = intval($xml_obj->attrs->height);
- if(!$height) {$height = 400;}
+ if(!$height) {$height = 300;}
$header_script = '';
if($map_count==1) {
@@ -411,15 +411,17 @@ function transHTML($xml_obj) {
$width = $width.'px';
}
$height = $height.'px';
- $view_code = ''.
- ''."\n";
+ $view_code = '';
+ // 이미지 리사이징 애드온 등을 회피하기 위해서 가장 마지막에 실행 되도록 함
+ $footer_code = '';
+ Context::addHtmlFooter($footer_code);
}
return $view_code;
}
- function getImageMapLink($center, $markers, $zoom, $width=600, $height=400) {
+ function getImageMapLink($center, $markers, $zoom, $width=600, $height=300) {
$output = "https://maps-api-ssl.google.com/maps/api/staticmap?center=".$center."&zoom=".$zoom."&size=".$width."x".$height;
$positions = explode(";", $markers);
foreach($positions as $position) {
diff --git a/tpl/daum_map.js b/tpl/daum_map.js
index 97c12f9..e27a84e 100644
--- a/tpl/daum_map.js
+++ b/tpl/daum_map.js
@@ -132,7 +132,7 @@ function getMaps() {
var center = map.getCenter();
jQuery("#width").val('600');
- jQuery("#height").val('400');
+ jQuery("#height").val('300');
map.setLevel(map_zoom);
}
@@ -281,7 +281,7 @@ function insertMap(obj) {
map_lat = map.getCenter().getLat();
map_lng = map.getCenter().getLng();
if(!width) {width = '600';}
- if(!height) {height = '400';}
+ if(!height) {height = '300';}
//XE에서 속성 삭제하는 방향으로 바뀐다면, alt 에 넣자
var img_var = {
diff --git a/tpl/daum_map.min.js b/tpl/daum_map.min.js
index ed6d541..1f7af53 100644
--- a/tpl/daum_map.min.js
+++ b/tpl/daum_map.min.js
@@ -1 +1 @@
-function toggle(e){obj=document.getElementById(e),"none"==obj.style.display?obj.style.display="block":obj.style.display="none"}function map_point(e){center=result_array[e].geometry.location,map.setCenter(center)}function view_list(){var e="";if(0===result_array.length)return void alert(no_result);for(var a=0;a'),1==result_array.length&&map_point("0");var r=result_array[a].formatted_address.split(" "),t=result_array[a].formatted_address.substring(result_array[a].formatted_address.lastIndexOf(r[r.length-3]));e+='"+t+""}e+="",jQuery("#result_list_layer").html(e),window.location.href="#view_list"}function showLocation(e){if(result_from="",e){var a=[];a.component="map_components",a.address=e,a.method="search";var r=["error","message","results"];exec_xml("editor","procEditorCall",a,function(a,r){complete_search(a,r,e)},r)}}function complete_search(e,a,r){var t=e.results;t=t?t.item:[],address_adder(t)}function address_adder(e){result_array=[],"undefined"==typeof e.length&&(e=[e]);for(var a=0;a',opener.editorFocus(opener.editorPrevSrl);var i=opener.editorGetIFrame(opener.editorPrevSrl);opener.editorReplaceHTML(i,m),opener.editorFocus(opener.editorPrevSrl),window.close()},s)}}var map_zoom=5,map_lat="",map_lng="",map="",marker="",map_markers=[],map_marker_positions="",modi_marker_pos="",saved_location=[],result_array=[],result_from="";jQuery(document).ready(function(){getMaps()});
\ No newline at end of file
+function toggle(e){obj=document.getElementById(e),"none"==obj.style.display?obj.style.display="block":obj.style.display="none"}function map_point(e){center=result_array[e].geometry.location,map.setCenter(center)}function view_list(){var e="";if(0===result_array.length)return void alert(no_result);for(var a=0;a'),1==result_array.length&&map_point("0");var r=result_array[a].formatted_address.split(" "),t=result_array[a].formatted_address.substring(result_array[a].formatted_address.lastIndexOf(r[r.length-3]));e+='"+t+""}e+="",jQuery("#result_list_layer").html(e),window.location.href="#view_list"}function showLocation(e){if(result_from="",e){var a=[];a.component="map_components",a.address=e,a.method="search";var r=["error","message","results"];exec_xml("editor","procEditorCall",a,function(a,r){complete_search(a,r,e)},r)}}function complete_search(e,a,r){var t=e.results;t=t?t.item:[],address_adder(t)}function address_adder(e){result_array=[],"undefined"==typeof e.length&&(e=[e]);for(var a=0;a',opener.editorFocus(opener.editorPrevSrl);var i=opener.editorGetIFrame(opener.editorPrevSrl);opener.editorReplaceHTML(i,m),opener.editorFocus(opener.editorPrevSrl),window.close()},s)}}var map_zoom=5,map_lat="",map_lng="",map="",marker="",map_markers=[],map_marker_positions="",modi_marker_pos="",saved_location=[],result_array=[],result_from="";jQuery(document).ready(function(){getMaps()});
\ No newline at end of file
diff --git a/tpl/google_map.js b/tpl/google_map.js
index 095c15e..64ee369 100644
--- a/tpl/google_map.js
+++ b/tpl/google_map.js
@@ -157,7 +157,7 @@ function getMaps() {
var center = map.getCenter();
jQuery("#width").val('600');
- jQuery("#height").val('400');
+ jQuery("#height").val('300');
map.setZoom(map_zoom);
}
@@ -311,7 +311,7 @@ function insertMap(obj) {
map_lat = map.getCenter().lat();
map_lng = map.getCenter().lng();
if(!width) {width = '600';}
- if(!height) {height = '400';}
+ if(!height) {height = '300';}
//XE에서 속성 삭제하는 방향으로 바뀐다면, alt 에 넣자
var img_var = {
diff --git a/tpl/google_map.min.js b/tpl/google_map.min.js
index acc38a8..e2a9f27 100644
--- a/tpl/google_map.min.js
+++ b/tpl/google_map.min.js
@@ -1 +1 @@
-function toggle(a){obj=document.getElementById(a),obj.style.display="none"==obj.style.display?"block":"none"}function map_point(a){center=result_array[a].geometry.location,map.setCenter(center)}function view_list(){var a="";if(0===result_array.length)return void alert(no_result);for(var b=0;b'),1==result_array.length&&map_point("0");var c=result_array[b].formatted_address.split(" "),d=result_array[b].formatted_address.substring(result_array[b].formatted_address.lastIndexOf(c[c.length-3]));a+='"+d+""}a+="",jQuery("#result_list_layer").html(a),window.location.href="#view_list"}function showLocation(a){if(result_from="",a){var b=[];b.component="map_components",b.address=a,b.method="search";var c=["error","message","results"];exec_xml("editor","procEditorCall",b,function(b,c){complete_search(b,c,a)},c)}}function complete_search(a){var b=a.results;b=b?b.item:[],address_adder(b)}function address_adder(a){result_array=[],"undefined"==typeof a.length&&(a=[a]);for(var b=0;b',opener.editorFocus(opener.editorPrevSrl);var i=opener.editorGetIFrame(opener.editorPrevSrl);opener.editorReplaceHTML(i,f),opener.editorFocus(opener.editorPrevSrl),window.close()},e)}}var map_zoom=13,map_lat="",map_lng="",map="",marker="",map_markers=[],map_marker_positions="",modi_marker_pos="",saved_location=[],result_array=[],result_from="";jQuery(document).ready(function(){getMaps()});
\ No newline at end of file
+function toggle(a){obj=document.getElementById(a),obj.style.display="none"==obj.style.display?"block":"none"}function map_point(a){center=result_array[a].geometry.location,map.setCenter(center)}function view_list(){var a="";if(0===result_array.length)return void alert(no_result);for(var b=0;b'),1==result_array.length&&map_point("0");var c=result_array[b].formatted_address.split(" "),d=result_array[b].formatted_address.substring(result_array[b].formatted_address.lastIndexOf(c[c.length-3]));a+='"+d+""}a+="",jQuery("#result_list_layer").html(a),window.location.href="#view_list"}function showLocation(a){if(result_from="",a){var b=[];b.component="map_components",b.address=a,b.method="search";var c=["error","message","results"];exec_xml("editor","procEditorCall",b,function(b,c){complete_search(b,c,a)},c)}}function complete_search(a){var b=a.results;b=b?b.item:[],address_adder(b)}function address_adder(a){result_array=[],"undefined"==typeof a.length&&(a=[a]);for(var b=0;b',opener.editorFocus(opener.editorPrevSrl);var i=opener.editorGetIFrame(opener.editorPrevSrl);opener.editorReplaceHTML(i,f),opener.editorFocus(opener.editorPrevSrl),window.close()},e)}}var map_zoom=13,map_lat="",map_lng="",map="",marker="",map_markers=[],map_marker_positions="",modi_marker_pos="",saved_location=[],result_array=[],result_from="";jQuery(document).ready(function(){getMaps()});
\ No newline at end of file
diff --git a/tpl/naver_map.js b/tpl/naver_map.js
index 7e7bccf..e2d8108 100644
--- a/tpl/naver_map.js
+++ b/tpl/naver_map.js
@@ -147,7 +147,7 @@ function getMaps() {
var center = map.getCenter();
jQuery("#width").val('600');
- jQuery("#height").val('400');
+ jQuery("#height").val('300');
map.setLevel(map_zoom);
}
@@ -291,7 +291,7 @@ function insertMap(obj) {
map_lat = map.getCenter().getLat();
map_lng = map.getCenter().getLng();
if(!width) {width = '600';}
- if(!height) {height = '400';}
+ if(!height) {height = '300';}
//XE에서 속성 삭제하는 방향으로 바뀐다면, alt 에 넣자
var img_var = {
diff --git a/tpl/naver_map.min.js b/tpl/naver_map.min.js
index e261102..b3f608b 100644
--- a/tpl/naver_map.min.js
+++ b/tpl/naver_map.min.js
@@ -1 +1 @@
-function toggle(e){obj=document.getElementById(e),obj.style.display="none"==obj.style.display?"block":"none"}function map_point(e){center=result_array[e].geometry.location,map.setCenter(center)}function view_list(){var e="";if(0==result_array.length)return void alert(no_result);for(var a=0;a'),1==result_array.length&&map_point("0");var r=result_array[a].formatted_address.split(" "),t=result_array[a].formatted_address.substring(result_array[a].formatted_address.lastIndexOf(r[r.length-3]));e+='"+t+""}e+="",jQuery("#result_list_layer").html(e),window.location.href="#view_list"}function showLocation(e){if(result_from="",e){var a=new Array;a.component="map_components",a.address=e,a.method="search";var r=new Array("error","message","results");exec_xml("editor","procEditorCall",a,function(a,r){complete_search(a,r,e)},r)}}function complete_search(e){var a=e.results;a=a?a.item:new Array,address_adder(a)}function address_adder(e){result_array=new Array,"undefined"==typeof e.length&&(e=new Array(e));for(var a=0;a',opener.editorFocus(opener.editorPrevSrl);var i=opener.editorGetIFrame(opener.editorPrevSrl);opener.editorReplaceHTML(i,o),opener.editorFocus(opener.editorPrevSrl),window.close()},n)}}var map_zoom=10,map_lat="",map_lng="",map="",marker="",map_markers=new Array,map_marker_positions="",modi_marker_pos="",saved_location=new Array,result_array=new Array,result_from="",oIcon="",tester="";jQuery(document).ready(function(){getMaps()});
\ No newline at end of file
+function toggle(e){obj=document.getElementById(e),obj.style.display="none"==obj.style.display?"block":"none"}function map_point(e){center=result_array[e].geometry.location,map.setCenter(center)}function view_list(){var e="";if(0==result_array.length)return void alert(no_result);for(var a=0;a'),1==result_array.length&&map_point("0");var r=result_array[a].formatted_address.split(" "),t=result_array[a].formatted_address.substring(result_array[a].formatted_address.lastIndexOf(r[r.length-3]));e+='"+t+""}e+="",jQuery("#result_list_layer").html(e),window.location.href="#view_list"}function showLocation(e){if(result_from="",e){var a=new Array;a.component="map_components",a.address=e,a.method="search";var r=new Array("error","message","results");exec_xml("editor","procEditorCall",a,function(a,r){complete_search(a,r,e)},r)}}function complete_search(e){var a=e.results;a=a?a.item:new Array,address_adder(a)}function address_adder(e){result_array=new Array,"undefined"==typeof e.length&&(e=new Array(e));for(var a=0;a',opener.editorFocus(opener.editorPrevSrl);var i=opener.editorGetIFrame(opener.editorPrevSrl);opener.editorReplaceHTML(i,o),opener.editorFocus(opener.editorPrevSrl),window.close()},n)}}var map_zoom=10,map_lat="",map_lng="",map="",marker="",map_markers=new Array,map_marker_positions="",modi_marker_pos="",saved_location=new Array,result_array=new Array,result_from="",oIcon="",tester="";jQuery(document).ready(function(){getMaps()});
\ No newline at end of file