google.charts.load('42', {'packages':['geochart']}); google.charts.setOnLoadCallback(drawVisualization); function drawVisualization() {var data = new google.visualization.DataTable(); data.addColumn('number', 'Lat'); data.addColumn('number', 'Lon'); data.addColumn('string', 'Country'); data.addColumn('number', 'Value'); data.addColumn({type:'string', role:'tooltip'});var ivalue = new Array(); data.addRows([[47.677950,9.173238,'Constance (04/07/2023)',0,'Une halte au lac de Constance']]); ivalue['47.677950'] = 'https://www.growupontheroad.com/fr/nos-destinations/europe/suisse/une-halte-au-lac-de-constance'; var options = { backgroundColor: {fill:'#FFFFFF',stroke:'#FFFFFF' ,strokeWidth:0 }, colorAxis: {minValue: 0, maxValue: 3, colors: ['#00BFFF','#00BFFF','#00BFFF','#00BFFF']}, legend: 'none', backgroundColor: {fill:'#FFFFFF',stroke:'#FFFFFF' ,strokeWidth:0 }, datalessRegionColor: '#EDEDED', displayMode: 'markers', enableRegionInteractivity: 'true', resolution: 'provinces', sizeAxis: {minValue: 1, maxValue:1,minSize:10, maxSize: 10}, region:'CH', keepAspectRatio: true, width:null, height:null, tooltip: {textStyle: {color: '#444444'}, trigger:'focus', isHtml: false} }; var chart = new google.visualization.GeoChart(document.getElementById('map_1638739781796')); google.visualization.events.addListener(chart, 'select', function() { var selection = chart.getSelection(); if (selection.length == 1) { var selectedRow = selection[0].row; var selectedRegion = data.getValue(selectedRow, 0); if(ivalue[selectedRegion] != '') { document.location = ivalue[selectedRegion]; } } }); chart.draw(data, options); }