{"id":32,"date":"2024-02-10T11:27:50","date_gmt":"2024-02-10T11:27:50","guid":{"rendered":"https:\/\/leonrutadelvino.com\/?p=32"},"modified":"2024-11-10T11:44:25","modified_gmt":"2024-11-10T11:44:25","slug":"maps-enoturismo-leon-ruta-del-vino","status":"publish","type":"post","link":"https:\/\/leonrutadelvino.com\/?p=32","title":{"rendered":"Maps Enoturismo Le\u00f3n Ruta del Vino"},"content":{"rendered":"<h1 class='srm_gmap_heading_1 '>Le\u00f3n Ruta del Vino<\/h1>            <script type=\"text\/javascript\">\r\n                jQuery(document).ready(function ($) {\r\n                    var wgm_map = new google.maps.Map(document.getElementById(\"srm_gmp_embed_1\"), {\r\n                        center: new google.maps.LatLng(42.61247032883823,-5.698858809918838),\r\n                        zoom: 10,\r\n                        mapTypeId: google.maps.MapTypeId.ROADMAP,\r\n                        scrollwheel: true,\r\n                        zoomControl: true,\r\n                        mapTypeControl: true,\r\n                        streetViewControl: true,\r\n                        fullscreenControl: true,\r\n                        draggable: true,\r\n                        disableDoubleClickZoom: false,\r\n                        panControl: true                    });\r\n                    var wgm_theme_json = '[]';\r\n                    if (wgm_theme_json.length > 0) {\r\n                        wgm_map.setOptions({ styles: JSON.parse(wgm_theme_json) });\r\n                    }\r\n                    \/\/ To view directions form and data\r\n                                        var wgm_data_1 = {\r\n                        'action': 'wpgmapembed_p_get_markers_by_map_id',\r\n                        'data': {\r\n                            map_id: '30',\r\n                            ajax_nonce: 'f4c838c814'\r\n                        }\r\n                    };\r\n                    var wgm_ajaxurl_1 = 'https:\/\/leonrutadelvino.com\/wp-admin\/admin-ajax.php'\r\n                    jQuery.post(wgm_ajaxurl_1, wgm_data_1, function (response) {\r\n                        response = JSON.parse(response);\r\n                        if (response.markers.length === 1) {\r\n                            var wgm_marker_to_1 = response.markers[0].marker_desc;\/\/.replace(\/&gt;\/g, '>').replace(\/&lt;\/g, '<');\r\n                            jQuery('#srm_gmap_to_1').val(wgm_marker_to_1.replace(\/(<([^>]+)>)\/gi, \"\"));\r\n                        }\r\n                        var wgm_default_marker_icon_1 = 'https:\/\/maps.gstatic.com\/mapfiles\/api-3\/images\/spotlight-poi2.png';\r\n                        if (response.markers.length > 0) {\r\n                            var custom_markers = [];\r\n                            var custom_marker_infowindows = [];\r\n                            response.markers.forEach(function (wgm_marker, i) {\r\n                                var wgm_marker_lat_lng_1 = wgm_marker.lat_lng.split(',');\r\n                                wgm_custom_marker_1 = new google.maps.Marker({\r\n                                    position: new google.maps.LatLng(wgm_marker_lat_lng_1[0], wgm_marker_lat_lng_1[1]),\r\n                                    title: wgm_marker.marker_name,\r\n                                    animation: google.maps.Animation.DROP,\r\n                                    icon: (wgm_marker.icon === '') ? wgm_default_marker_icon_1 : wgm_marker.icon\r\n                                });\r\n                                custom_markers[i] = wgm_custom_marker_1;\r\n                                wgm_custom_marker_1.setMap(wgm_map);\r\n                                var wgm_marker_name_1 = (wgm_marker.marker_name !== null) ? ('<span class=\"info_content_title\" style=\"font-size:18px;font-weight: bold;font-family: Arial;\">'\r\n                                    + wgm_marker.marker_name +\r\n                                    '<\/span><br\/>') : '';\r\n                                \/\/wgm_marker.marker_desc = wgm_marker.marker_desc.replace(\/&gt;\/g, '>').replace(\/&lt;\/g, '<');\r\n                                custom_marker_infowindow = new google.maps.InfoWindow({\r\n                                    content: wgm_marker_name_1 + wgm_marker.marker_desc\r\n                                });\r\n                                custom_marker_infowindows[i] = custom_marker_infowindow;\r\n                                if (wgm_marker.show_desc_by_default === '1') {\r\n                                    custom_marker_infowindow.open({\r\n                                        anchor: wgm_custom_marker_1,\r\n                                        shouldFocus: false\r\n                                    });\r\n                                } else {\r\n                                    google.maps.event.addListener(wgm_custom_marker_1, 'click', function () {\r\n                                        custom_marker_infowindows[i].open({\r\n                                            anchor: custom_markers[i],\r\n                                            shouldFocus: false\r\n                                        });\r\n                                    });\r\n                                }\r\n                                if (wgm_marker.have_marker_link === '1') {\r\n                                    google.maps.event.addListener(wgm_custom_marker_1, 'click', function () {\r\n                                        var wgm_target = '_self';\r\n                                        if (wgm_marker.marker_link_new_tab === '1') {\r\n                                            wgm_target = '_blank';\r\n                                        }\r\n                                        window.open(wgm_marker.marker_link, wgm_target);\r\n                                    });\r\n                                }\r\n                            });\r\n                        }\r\n                    });\r\n                });\r\n\r\n            <\/script>\r\n\r\n            <div id=\"srm_gmp_embed_1\"\r\n                style=\"width:100% !important;height:300px  !important; \">\r\n            <\/div>\r\n                    \n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5,7,6,8],"tags":[],"class_list":["post-32","post","type-post","status-publish","format-standard","hentry","category-bodegas","category-hoteles","category-restaurantes","category-tiendas-especializadas"],"_links":{"self":[{"href":"https:\/\/leonrutadelvino.com\/index.php?rest_route=\/wp\/v2\/posts\/32","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/leonrutadelvino.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/leonrutadelvino.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/leonrutadelvino.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/leonrutadelvino.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=32"}],"version-history":[{"count":2,"href":"https:\/\/leonrutadelvino.com\/index.php?rest_route=\/wp\/v2\/posts\/32\/revisions"}],"predecessor-version":[{"id":34,"href":"https:\/\/leonrutadelvino.com\/index.php?rest_route=\/wp\/v2\/posts\/32\/revisions\/34"}],"wp:attachment":[{"href":"https:\/\/leonrutadelvino.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=32"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/leonrutadelvino.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=32"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/leonrutadelvino.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=32"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}