{"id":1681,"date":"2020-12-17T10:23:54","date_gmt":"2020-12-17T09:23:54","guid":{"rendered":"https:\/\/viva.rauschmayer.com\/dealers\/"},"modified":"2022-12-15T10:42:59","modified_gmt":"2022-12-15T09:42:59","slug":"dealers","status":"publish","type":"page","link":"https:\/\/viva.rauschmayer.com\/de\/dealers\/","title":{"rendered":"Dealers"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-page\" data-elementor-id=\"1681\" class=\"elementor elementor-1681 elementor-292\" data-elementor-post-type=\"page\">\n\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-6dc8ac2 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"6dc8ac2\" data-element_type=\"section\" data-e-type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-no\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-37baab0\" data-id=\"37baab0\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap\">\n\t\t\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-b6d2456 elementor-section-full_width elementor-section-height-default elementor-section-height-default\" data-id=\"b6d2456\" data-element_type=\"section\" data-e-type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-no\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-ce4c042\" data-id=\"ce4c042\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-d7f58df elementor-widget elementor-widget-shortcode\" data-id=\"d7f58df\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"shortcode.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-shortcode\">\n    <script type=\"text\/javascript\">\n    var map;\n    function initMap(mlat,mlon,zoom) {\n        var gmarkers = [];\n        \n        \/\/console.log(mlat+','+mlon);\n\n        var stylized = [\n            {\n                \"featureType\": \"all\",\n                \"elementType\": \"geometry.fill\",\n                \"stylers\": [\n                    {\n                        \"weight\": \"2.00\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"all\",\n                \"elementType\": \"geometry.stroke\",\n                \"stylers\": [\n                    {\n                        \"color\": \"#9c9c9c\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"all\",\n                \"elementType\": \"labels.text\",\n                \"stylers\": [\n                    {\n                        \"visibility\": \"on\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"landscape\",\n                \"elementType\": \"all\",\n                \"stylers\": [\n                    {\n                        \"color\": \"#f2f2f2\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"landscape\",\n                \"elementType\": \"geometry.fill\",\n                \"stylers\": [\n                    {\n                        \"color\": \"#ffffff\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"landscape.man_made\",\n                \"elementType\": \"geometry.fill\",\n                \"stylers\": [\n                    {\n                        \"color\": \"#ffffff\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"poi\",\n                \"elementType\": \"all\",\n                \"stylers\": [\n                    {\n                        \"visibility\": \"off\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"road\",\n                \"elementType\": \"all\",\n                \"stylers\": [\n                    {\n                        \"saturation\": -100\n                    },\n                    {\n                        \"lightness\": 45\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"road\",\n                \"elementType\": \"geometry.fill\",\n                \"stylers\": [\n                    {\n                        \"color\": \"#eeeeee\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"road\",\n                \"elementType\": \"labels.text.fill\",\n                \"stylers\": [\n                    {\n                        \"color\": \"#7b7b7b\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"road\",\n                \"elementType\": \"labels.text.stroke\",\n                \"stylers\": [\n                    {\n                        \"color\": \"#ffffff\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"road.highway\",\n                \"elementType\": \"all\",\n                \"stylers\": [\n                    {\n                        \"visibility\": \"simplified\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"road.arterial\",\n                \"elementType\": \"labels.icon\",\n                \"stylers\": [\n                    {\n                        \"visibility\": \"off\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"transit\",\n                \"elementType\": \"all\",\n                \"stylers\": [\n                    {\n                        \"visibility\": \"off\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"water\",\n                \"elementType\": \"all\",\n                \"stylers\": [\n                    {\n                        \"color\": \"#46bcec\"\n                    },\n                    {\n                        \"visibility\": \"on\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"water\",\n                \"elementType\": \"geometry.fill\",\n                \"stylers\": [\n                    {\n                        \"color\": \"#c8d7d4\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"water\",\n                \"elementType\": \"labels.text.fill\",\n                \"stylers\": [\n                    {\n                        \"color\": \"#070707\"\n                    }\n                ]\n            },\n            {\n                \"featureType\": \"water\",\n                \"elementType\": \"labels.text.stroke\",\n                \"stylers\": [\n                    {\n                        \"color\": \"#ffffff\"\n                    }\n                ]\n            }\n        ];\n        \n        var mlats =  mlat;\n        var mlons =  mlon;\n\n        map = new google.maps.Map(document.getElementById('map'), {\n            center: {lat: parseFloat(mlats), lng: parseFloat(mlons)},\n            zoom: zoom,\n            styles: stylized,\n            mapTypeControl: false,\n            streetViewControl: false,\n            fullscreenControl: false,\n            optimized: false\n        });\n\n    }\n        \n\tjQuery.noConflict();\n\tjQuery(document).ready(function() {\n        \n        var infowindow = new google.maps.InfoWindow();\n    \n        function deleteOverlays() {\n            if (gmarkers) {\n                for (i in gmarkers) {\n                    gmarkers[i].setMap(null);\n                }\n                gmarkers.length = 0;\n            }\n        }\n\n        initMap(51.1657,10.4515,6);\n        \n        function createInfoWindow(location,marker) {\n\n            google.maps.event.addListener(marker, 'click', function() {\n\n                \/\/console.log(location.title);\n\n                infowindow.close();\n                infowindow.setContent('<a href=\"'+location.link+'\"><strong>'+location.title+'<\/strong><\/a><br\/>'+location.address); \n                infowindow.open(map,marker);\n\n            });\n            \n        }\n\n        function writeMapPoints(Locations)\n        {\n            \n            \/\/console.log(Locations);\n\n            var gmarkers = [];\n\n            if (Locations.length>0) {\n\n                for (i=0; i<Locations.length; i++) { \n\n                    var location = Locations[i];\n\n                    var bits = location.latlng.split(\",\");\n                    var latLng = new google.maps.LatLng(bits[0], bits[1]);\n                    \n                    var marker = new google.maps.Marker({\n                        position: latLng,\n                        icon: location.icon,\n                        map: map\n                    });\n\n\t\t\t        marker.metadata = {id: location.point};\n                    \n                    createInfoWindow(location,marker);\n                    \n                    gmarkers.push(marker);\n\n                }\n\n                var markerCluster = new MarkerClusterer(map, gmarkers, {imagePath: 'https:\/\/viva.rauschmayer.com\/wp-content\/plugins\/rauschmayer-plugin\/\/images\/m'});\n                jQuery('#map .loader').remove();\n\n            } else {\n\n                \/*initMap();*\/\n                jQuery('#map .loader').remove();\n\n            }\n        }\n\n        function getMapPoints(type,loader) {\n\n            if(loader) {\n\n                jQuery('#map').append('<div class=\"loader\"><img decoding=\"async\" src=\"https:\/\/viva.rauschmayer.com\/wp-content\/plugins\/rauschmayer-plugin\/\/images\/ajax-loader.gif\" \/><\/div>');\n\n            }\n\n            var x = 0;\n            \/*var location = jQuery(\"#filter_locations\").val();\n            var division = jQuery(\"#filter_divisions\").val();*\/\n\n            jQuery.ajax({type: \"GET\", dataType: \"json\", data: \"lat=\"+jQuery(\"#mlat\").val()+\"&lon=\"+jQuery(\"#mlon\").val()+\"\", url: \"https:\/\/viva.rauschmayer.com\/wp-content\/plugins\/rauschmayer-plugin\/\/scripts\/json-map-points.php\", success: function(data)\n            {\n\n                \/\/console.log(data);\n\n                \/\/initMap();\n                writeMapPoints(data);\n\n            },\n            error: function (request, status, error) {\n                \/\/jQuery(\"#olist\").html('<p>'+error+'<\/p>'+request.responseText);\n            }\n            });\n\n        }\n\n        getMapPoints('',false);\n        \n         function getLatLng() {\n\n            geocoder = new google.maps.Geocoder();\n\n            if (geocoder) {\n\n                var sloc = '';\n                sloc += jQuery(\"#dsearch\").val()+', '+jQuery(\"#dcountry\").val();\n\n                geocoder.geocode( { \"address\": sloc}, function(results, status) {\n\n                    function objectToString(o){\n\n                        var parse = function(_o){\n\n                            var a = [], t;\n\n                            for(var p in _o){\n\n                                if(_o.hasOwnProperty(p)){\n\n                                    t = _o[p];\n\n                                    if(t && typeof t == \"object\"){\n\n                                        a[a.length]= p + \":{ \" + arguments.callee(t).join(\", \") + \"}\";\n\n                                    }\n                                    else {\n\n                                        if(typeof t == \"string\"){\n\n                                            a[a.length] = [ p+ \": \\\"\" + t.toString() + \"\\\"\" ];\n                                        }\n                                        else{\n                                            a[a.length] = [ p+ \": \" + t.toString()];\n                                        }\n\n                                    }\n                                }\n                            }\n\n                            return a;\n\n                        }\n\n                        return \"{\" + parse(o).join(\", \") + \"}\";\n\n                    }\n\n                    var coordinates1 = results[0].geometry.location.lat();\n                    var coordinates2 = results[0].geometry.location.lng();\n\n                    \/\/console.log(coordinates1+','+coordinates2);\n\n                    jQuery(\"#mlat\").val(coordinates1);\n                    jQuery(\"#mlon\").val(coordinates2);\n                    \n                    initMap(jQuery(\"#mlat\").val(),jQuery(\"#mlon\").val(),9);\n                    getMapPoints('',false);\n            \n                    jQuery.ajax({type: \"GET\", data: \"lat=\"+jQuery(\"#mlat\").val()+\"&lon=\"+jQuery(\"#mlon\").val()+\"\", url: \"https:\/\/viva.rauschmayer.com\/wp-content\/plugins\/rauschmayer-plugin\/\/scripts\/dealer-list.php\", success: function(data)\n                    {\n\n                        jQuery(\"#dlist\").html(data);\n\n                    }\n                    });\n\n                });\n            }\n\n        }\n\n        \/*jQuery(document.body).on(\"blur\", \"#dsearch\", function() {\n\n            getLatLng();\n\n        });*\/\n\n        jQuery(document.body).on(\"click\", \".sbutton\", function() {\n            \n            \/\/console.log(jQuery(\"#mlat\").val()+','+jQuery(\"#mlon\").val());\n\n            getLatLng();\n\n        });\n        \n\t});\n\t<\/script>\n\n    <div class=\"col-sm-3 sdealers\">\n        \n        <h2>\n            H\u00e4ndler in deiner N\u00e4he        <\/h2>\n        <small>PLZ \/ Stadt<\/small>\n        <div class=\"clear\"><\/div>\n        <select id=\"dcountry\" style=\"width:20%;float:left;height:41px;border:1px solid #000;\">\n            <option value=\"Germany\">DE<\/option>\n            <option value=\"Austria\">AT<\/option>\n            <option value=\"Switzerland\">CH<\/option>\n        <\/select><input type=\"text\" id=\"dsearch\" style=\"width:80%;float:left;\" placeHolder=\"PLZ \/ Stadt...\" \/>\n        <input type=\"hidden\" id=\"mlat\" value=\"\" \/>\n\t\t<input type=\"hidden\" id=\"mlon\" value=\"\" \/>\n        <div class=\"sbutton\">\n            <i class=\"fa fa-search\"><\/i>\n        <\/div>\n        \n        <div id=\"dlist\">\n            \t\t\t<div class=\"margin15\"><\/div>\n\t\t\t\t<div class=\"dealer\">\n\t\t\t\t\t<h3><a href=\"https:\/\/viva.rauschmayer.com\/de\/dealers\/juwelier-bungenstock-gmbh\/\">Juwelier Bungenstock GmbH<\/a><\/h3>\n\t\t\t\t\tSchuhstr. 21, 38100 Braunschweig, Germany\t\t\t\t<\/div>\n\n\t\t\t\n\t\t\t\t<div class=\"dealer\">\n\t\t\t\t\t<h3><a href=\"https:\/\/viva.rauschmayer.com\/de\/dealers\/lubbers\/\">L\u00fcbbers<\/a><\/h3>\n\t\t\t\t\tSchlo\u00dfstr. 8, 51429 Bergisch Gladbach, Germany\t\t\t\t<\/div>\n\n\t\t\t        <\/div>\n        \n        \n    <\/div>\n\n    <div class=\"col-sm-9 map\">\n\n        <div id=\"map\" style=\"height:800px;width:100%;\"><\/div>\n\n    <\/div>\n\n<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"elementor_header_footer","meta":{"footnotes":""},"class_list":["post-1681","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/viva.rauschmayer.com\/de\/wp-json\/wp\/v2\/pages\/1681","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/viva.rauschmayer.com\/de\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/viva.rauschmayer.com\/de\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/viva.rauschmayer.com\/de\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/viva.rauschmayer.com\/de\/wp-json\/wp\/v2\/comments?post=1681"}],"version-history":[{"count":3,"href":"https:\/\/viva.rauschmayer.com\/de\/wp-json\/wp\/v2\/pages\/1681\/revisions"}],"predecessor-version":[{"id":1998,"href":"https:\/\/viva.rauschmayer.com\/de\/wp-json\/wp\/v2\/pages\/1681\/revisions\/1998"}],"wp:attachment":[{"href":"https:\/\/viva.rauschmayer.com\/de\/wp-json\/wp\/v2\/media?parent=1681"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}