Hi all,

Need help in Google Geocharts, I have this two code below one with 
countries and different color and the other with link. How can I merge 
them. As countries with different colors and link complete code is needed 
for one single world map using Geocharts.

*CODE with Countries and Color:*

<html>
  <head>
    <script type="text/javascript" 
src="https://www.google.com/jsapi";></script>
    <script type="text/javascript">
      google.load("visualization", "1", {packages:["geochart"]});
      google.setOnLoadCallback(drawRegionsMap);

      function drawRegionsMap() {

        var data = google.visualization.arrayToDataTable([
          ['Country', 'Popularity'],
          ['Aarhus', 200],
          ['Alabama', 200],
          ['Alberta', 200],
          ['Albuquerque', 200],
          ['Alkmaar', 200],
          ['Allerdale', 200],
          ['Amsterdam O+S', 200],
          ['Angers', 200],
          ['Ann Arbor', 200],
          ['Antwerp', 200],
          ['Aquitaine and Gironde', 200],
          ['Aragon', 200],
          ['Arizona', 200],
          ['Arvada', 200],
          ['Asheville', 200],
          ['Asturias', 200],
          ['Atlanta', 200],
          ['Austin', 200],
          ['Australia', 400],
          ['Australian Capital Territory', 200],
          ['Austria', 200],
          ['Badalona', 200],
          ['Baden-Württemberg', 200],
          ['Bahía Blanca', 200],
          ['Bahrain', 200],
          ['Balearic Islands', 200],
          ['Baltimore', 200],
          ['Barcelona', 200],
          ['Bari', 200],
          ['Belgium', 200],
          ['Belleville', 200],
          ['Berlin', 200],
          ['Birmingham', 200],
          ['Bologna', 200],
          ['Boston', 200],
          ['Boston Enterprise GIS', 200],
          ['Brazil', 10],
          ['Brazilian Federal Senate', 200],
          ['Bremen', 200],
          ['Brisbane', 200],
          ['British Columbia', 200],
          ['British Columbia Local Government', 200],
          ['Buenos Aires, Argentina', 200],
          ['Burlington', 200],
          ['Burlington', 200],
          ['California', 200],
          ['Canada', 2000],
          ['Castilla-La Mancha', 200],
          ['Catalonya', 200],
          ['Chamber of Deputies', 200],
          ['Champaign', 200],
          ['Chicago', 200],
          ['Chile', 310],
          ['China', 800],
          ['Colorado', 200],
          ['Connecticut', 200],
          ['Cook County', 200],
          ['Costa Rica', 200],
          ['County of Grand Prairie No. 1', 200],
          ['CSIRO', 200],
          ['Dailan', 200],
          ['Delaware', 200],
          ['Denmark', 200],
          ['Denver', 200],
          ['Denver Regional Council', 200],
          ['District of Columbia', 200],
          ['District of North Vancouver', 200],
          ['Edmonton', 200],
          ['Enschede', 200],
          ['Environmental Portal', 200],
          ['Estonia', 200],
          ['European Union', 200],
          ['Euskadi (Basque Country)', 200],
          ['Fingal', 200],
          ['Finland', 800],
          ['Florence', 200],
          ['Florida', 200],
          ['France', 350],
          ['Fredericton', 200],
          ['Galicia', 200],
          ['Georgia', 200],
          ['Germany', 200],
          ['Ghana', 200],
          ['Gilpin County', 200],
          ['Graz', 200],
          ['Great Manchester', 200],
          ['Greece', 200],
          ['Guelph', 200],
          ['Halifax', 200],
          ['Hamburg', 200],
          ['Hamilton', 200],
          ['Hauts-de-Seine', 200],
          ['Hawaii', 200],
          ['Hawaii GIS', 200],
          ['Helsinki Region Infoshare', 200],
          ['Hong Kong', 200],
          ['Honolulu', 200],
          ['Houston', 200],
          ['Illinois', 200],
          ['India', 100],
          ['Indiana', 200],
          ['Indonesia', 650],
          ['Iowa', 200],
          ['Ireland', 200],
          ['Italy', 200],
          ['Italy Senate', 200],
          ['Japan', 2000],
          ['Junta de Castilla y León', 200],
          ['Jyväskylä', 200],
          ['Kansas', 200],
          ['Kansas City', 200],
          ['Kent', 200],
          ['Kentucky', 200],
          ['Kenya', 1200],
          ['King County', 200],
          ['La Rochelle', 200],
          ['Langley', 200],
          ['Las Vegas', 200],
          ['Le Mans', 200],
          ['Leipzig', 200],
          ['Lexington', 200],
          ['Lichfield', 200],
          ['Lima', 200],
          ['Linz', 200],
          ['Lleida', 200],
          ['Loire-Atlantique', 200],
          ['Lombardy', 200],
          ['London', 200],
          ['Los Angeles', 200],
          ['Louisiana', 200],
          ['Louisville', 200],
          ['Lucca', 200],
          ['Madison', 200],
          ['Maine', 200],
          ['Manchester', 200],
          ['Maryland', 200],
          ['Massachusetts', 200],
          ['Medicine Hat', 200],
          ['Merton Council', 200],
          ['METI', 200],
          ['Mexico', 300],
          ['Michigan', 200],
          ['Milan', 200],
          ['Minnesota', 200],
          ['Misiones Province, Argentina', 200],
          ['Mississauga', 200],
          ['Missouri', 200],
          ['Moers', 200],
          ['Moldova', 200],
          ['Montana', 200],
          ['Montevideo', 200],
          ['Montgomery County', 200],
          ['Montpellier', 200],
          ['Montreal', 200],
          ['Morocco', 200],
          ['Moscow', 200],
          ['Mosman Council', 200],
          ['Nanaimo', 200],
          ['Nantes', 200],
          ['Navarre', 200],
          ['NC OpenBook', 200],
          ['Nebraska', 200],
          ['Netherlands', 200],
          ['New Hampshire', 200],
          ['New Mexico', 200],
          ['New Orleans', 200],
          ['New South Wales', 200],
          ['New York', 200],
          ['New York City', 200],
          ['New Zealand', 180],
          ['Niagara Falls', 200],
          ['Niagara Region', 200],
          ['Niederösterreich', 200],
          ['North Carolina', 200],
          ['North Dakota GIS Hub', 200],
          ['North Devon Council', 200],
          ['North Okanagan', 200],
          ['Norway', 333],
          ['Novo Hamburgo', 200],
          ['NY Department of Health', 200],
          ['NY State Senate', 200],
          ['Ohio', 200],
          ['Oklahoma', 200],
          ['Oman', 20],
          ['Ontario', 200],
          ['Oregon', 200],
          ['Ottawa', 200],
          ['Palo Alto', 200],
          ['Pamplona', 200],
          ['Paris', 200],
          ['Peru', 600],
          ['Philadelphia', 200],
          ['Philippines ', 200],
          ['Piedmont', 200],
          ['Portland', 200],
          ['Portugal', 200],
          ['Prince George', 200],
          ['Providence', 200],
          ['Puglia', 200],
          ['Québec (City)', 200],
          ['Québec (Province)', 200],
          ['Queensland', 200],
          ['Raleigh', 200],
          ['Red Deer', 200],
          ['Redbridge', 200],
          ['Regina', 200],
          ['Region of Peel', 200],
          ['Rennes', 200],
          ['Republic of Korea', 300],
          ['Rheinland Pfalz', 200],
          ['Rhode Island', 200],
          ['Rockford', 200],
          ['Rome (Province)', 200],
          ['Rostock', 200],
          ['Rotterdam', 200],
          ['Russia', 1800],
          ['Saanich', 200],
          ['Salford City Council', 200],
          ['San Francisco', 200],
          ['San Mateo County', 200],
          ['Santa Cruz', 200],
          ['Sao Paulo', 200],
          ['Saône-et-Loire', 200],
          ['Sardinia', 200],
          ['Saskatoon', 200],
          ['Saudi Arabia', 1000],
          ['Scottsdale', 200],
          ['Seattle', 200],
          ['Seoul', 200],
          ['Shizuoka Prefecture(Shizuoka)', 200],
          ['Singapore', 200],
          ['Slovak Republic', 200],
          ['Somerville', 200],
          ['South Australia', 200],
          ['South Australia Spatial Planning', 200],
          ['South Bend', 200],
          ['South Dakota', 200],
          ['Spain', 698],
          ['Stockholm', 200],
          ['Surrey', 200],
          ['Sutton', 200],
          ['Sweden', 700],
          ['Tampere', 200],
          ['Tennessee', 200],
          ['Terrassa', 200],
          ['Texas', 200],
          ['Texas Transparency', 200],
          ['Timor Leste', 200],
          ['Toronto', 200],
          ['Toulouse', 200],
          ['Trafford Council', 200],
          ['Trentino', 200],
          ['Trento', 200],
          ['Tunisia', 200],
          ['Turin', 200],
          ['Tuscany', 200],
          ['Tyrol', 200],
          ['Udine', 200],
          ['United Arab Emirates', 200],
          ['United Kingdom', 200],
          ['United Nations', 200],
          ['Uruguay', 200],
          ['Utah', 200],
          ['Vancouver', 200],
          ['Veneto', 200],
          ['Venice', 200],
          ['Vermont', 200],
          ['Vicenza Geodata', 200],
          ['Victoria', 200],
          ['Vienna', 200],
          ['Virginia', 200],
          ['Vorarlberg', 200],
          ['Wake County', 200],
          ['Warwickshire', 200],
          ['Washington', 200],
          ['Waterloo', 200],
          ['Weatherford', 200],
          ['Wellington', 200],
          ['Western Australia – NewSLIP', 200],
          ['Windsor', 200],
          ['Wyre Council', 200],
          ['Zaragoza', 200],
          ['Zurich', 200]
        ]);
     
 var options = {
    //Put your color hex code here
    colors: ['#FF0000'] //eg. red
};
        
var options = {
    //region: 'IT',
    //displayMode: 'markers',
    colorAxis: {colors: ['yellow', 'blue', 'green', 'orange', 'lightgreen', 
'red']}
  };



        var chart = new 
google.visualization.GeoChart(document.getElementById('regions_div'));

        chart.draw(data, options);
      }
    </script>
  </head>
  <body>
    <div id="regions_div" style="width: 900px; height: 500px;"></div>
  </body>
</html>


*CODE with Link:*

<html>
  <head>
    <script type="text/javascript" 
src="https://www.google.com/jsapi";></script>
    <script type="text/javascript">
      google.load("visualization", "1", {packages:["geochart"]});
      google.setOnLoadCallback(drawRegionsMap);

      function drawRegionsMap() {

        var data = google.visualization.arrayToDataTable([
          ['Country', 'link'],
          ['Aarhus', ''],
          ['Alabama', ''],
          ['Alberta', ''],
          ['Albuquerque', ''],
          ['Alkmaar', ''],
          ['Allerdale', ''],
          ['Amsterdam O+S', ''],
          ['Angers', ''],
          ['Ann Arbor', ''],
          ['Antwerp', ''],
          ['Aquitaine and Gironde', ''],
          ['Aragon', ''],
          ['Arizona', ''],
          ['Arvada', ''],
          ['Asheville', ''],
          ['Asturias', ''],
          ['Atlanta', ''],
          ['Austin', ''],
          ['Australia', ''],
          ['Australian Capital Territory', ''],
          ['Austria', ''],
          ['Badalona', ''],
          ['Baden-Württemberg', ''],
          ['Bahía Blanca', ''],
          ['Bahrain', ''],
          ['Balearic Islands', ''],
          ['Baltimore', ''],
          ['Barcelona', ''],
          ['Bari', ''],
          ['Belgium', ''],
          ['Belleville', ''],
          ['Berlin', ''],
          ['Birmingham', ''],
          ['Bologna', ''],
          ['Boston', ''],
          ['Boston Enterprise GIS', ''],
          ['Brazil', ''],
          ['Brazilian Federal Senate', ''],
          ['Bremen', ''],
          ['Brisbane', ''],
          ['British Columbia', ''],
          ['British Columbia Local Government', ''],
          ['Buenos Aires, Argentina', ''],
          ['Burlington', ''],
          ['Burlington', ''],
          ['California', ''],
          ['Canada', 'http://www.orf.at'],
          ['Castilla-La Mancha', ''],
          ['Catalonya', ''],
          ['Chamber of Deputies', ''],
          ['Champaign', ''],
          ['Chicago', ''],
          ['Chile', ''],
          ['China', ''],
          ['Colorado', ''],
          ['Connecticut', ''],
          ['Cook County', ''],
          ['Costa Rica', ''],
          ['County of Grand Prairie No. 1', ''],
          ['CSIRO', ''],
          ['Dailan', ''],
          ['Delaware', ''],
          ['Denmark', ''],
          ['Denver', ''],
          ['Denver Regional Council', ''],
          ['District of Columbia', ''],
          ['District of North Vancouver', ''],
          ['Edmonton', ''],
          ['Enschede', ''],
          ['Environmental Portal', ''],
          ['Estonia', ''],
          ['European Union', ''],
          ['Euskadi (Basque Country)', ''],
          ['Fingal', ''],
          ['Finland', ''],
          ['Florence', ''],
          ['Florida', ''],
          ['France', ''],
          ['Fredericton', ''],
          ['Galicia', ''],
          ['Georgia', ''],
          ['Germany', ''],
          ['Ghana', ''],
          ['Gilpin County', ''],
          ['Graz', ''],
          ['Great Manchester', ''],
          ['Greece', ''],
          ['Guelph', ''],
          ['Halifax', ''],
          ['Hamburg', ''],
          ['Hamilton', ''],
          ['Hauts-de-Seine', ''],
          ['Hawaii', ''],
          ['Hawaii GIS', ''],
          ['Helsinki Region Infoshare', ''],
          ['Hong Kong', ''],
          ['Honolulu', ''],
          ['Houston', ''],
          ['Illinois', ''],
          ['India', ''],
          ['Indiana', ''],
          ['Indonesia', ''],
          ['Iowa', ''],
          ['Ireland', ''],
          ['Italy', ''],
          ['Italy Senate', ''],
          ['Japan', ''],
          ['Junta de Castilla y León', ''],
          ['Jyväskylä', ''],
          ['Kansas', ''],
          ['Kansas City', ''],
          ['Kent', ''],
          ['Kentucky', ''],
          ['Kenya', ''],
          ['King County', ''],
          ['La Rochelle', ''],
          ['Langley', ''],
          ['Las Vegas', ''],
          ['Le Mans', ''],
          ['Leipzig', ''],
          ['Lexington', ''],
          ['Lichfield', ''],
          ['Lima', ''],
          ['Linz', ''],
          ['Lleida', ''],
          ['Loire-Atlantique', ''],
          ['Lombardy', ''],
          ['London', ''],
          ['Los Angeles', ''],
          ['Louisiana', ''],
          ['Louisville', ''],
          ['Lucca', ''],
          ['Madison', ''],
          ['Maine', ''],
          ['Manchester', ''],
          ['Maryland', ''],
          ['Massachusetts', ''],
          ['Medicine Hat', ''],
          ['Merton Council', ''],
          ['METI', ''],
          ['Mexico', ''],
          ['Michigan', ''],
          ['Milan', ''],
          ['Minnesota', ''],
          ['Misiones Province, Argentina', ''],
          ['Mississauga', ''],
          ['Missouri', ''],
          ['Moers', ''],
          ['Moldova', ''],
          ['Montana', ''],
          ['Montevideo', ''],
          ['Montgomery County', ''],
          ['Montpellier', ''],
          ['Montreal', ''],
          ['Morocco', ''],
          ['Moscow', ''],
          ['Mosman Council', ''],
          ['Nanaimo', ''],
          ['Nantes', ''],
          ['Navarre', ''],
          ['NC OpenBook', ''],
          ['Nebraska', ''],
          ['Netherlands', ''],
          ['New Hampshire', ''],
          ['New Mexico', ''],
          ['New Orleans', ''],
          ['New South Wales', ''],
          ['New York', ''],
          ['New York City', ''],
          ['New Zealand', ''],
          ['Niagara Falls', ''],
          ['Niagara Region', ''],
          ['Niederösterreich', ''],
          ['North Carolina', ''],
          ['North Dakota GIS Hub', ''],
          ['North Devon Council', ''],
          ['North Okanagan', ''],
          ['Norway', ''],
          ['Novo Hamburgo', ''],
          ['NY Department of Health', ''],
          ['NY State Senate', ''],
          ['Ohio', ''],
          ['Oklahoma', ''],
          ['Oman', ''],
          ['Ontario', ''],
          ['Oregon', ''],
          ['Ottawa', ''],
          ['Palo Alto', ''],
          ['Pamplona', ''],
          ['Paris', ''],
          ['Peru', ''],
          ['Philadelphia', ''],
          ['Philippines ', ''],
          ['Piedmont', ''],
          ['Portland', ''],
          ['Portugal', ''],
          ['Prince George', ''],
          ['Providence', ''],
          ['Puglia', ''],
          ['Québec (City)', ''],
          ['Québec (Province)', ''],
          ['Queensland', ''],
          ['Raleigh', ''],
          ['Red Deer', ''],
          ['Redbridge', ''],
          ['Regina', ''],
          ['Region of Peel', ''],
          ['Rennes', ''],
          ['Republic of Korea', ''],
          ['Rheinland Pfalz', ''],
          ['Rhode Island', ''],
          ['Rockford', ''],
          ['Rome (Province)', ''],
          ['Rostock', ''],
          ['Rotterdam', ''],
          ['Russia', ''],
          ['Saanich', ''],
          ['Salford City Council', ''],
          ['San Francisco', ''],
          ['San Mateo County', ''],
          ['Santa Cruz', ''],
          ['Sao Paulo', ''],
          ['Saône-et-Loire', ''],
          ['Sardinia', ''],
          ['Saskatoon', ''],
          ['Saudi Arabia', ''],
          ['Scottsdale', ''],
          ['Seattle', ''],
          ['Seoul', ''],
          ['Shizuoka Prefecture(Shizuoka)', ''],
          ['Singapore', ''],
          ['Slovak Republic', ''],
          ['Somerville', ''],
          ['South Australia', ''],
          ['South Australia Spatial Planning', ''],
          ['South Bend', ''],
          ['South Dakota', ''],
          ['Spain', ''],
          ['Stockholm', ''],
          ['Surrey', ''],
          ['Sutton', ''],
          ['Sweden', ''],
          ['Tampere', ''],
          ['Tennessee', ''],
          ['Terrassa', ''],
          ['Texas', ''],
          ['Texas Transparency', ''],
          ['Timor Leste', ''],
          ['Toronto', ''],
          ['Toulouse', ''],
          ['Trafford Council', ''],
          ['Trentino', ''],
          ['Trento', ''],
          ['Tunisia', ''],
          ['Turin', ''],
          ['Tuscany', ''],
          ['Tyrol', ''],
          ['Udine', ''],
          ['United Arab Emirates', ''],
          ['United Kingdom', ''],
          ['United Nations', ''],
          ['Uruguay', ''],
          ['Utah', ''],
          ['Vancouver', ''],
          ['Veneto', ''],
          ['Venice', ''],
          ['Vermont', ''],
          ['Vicenza Geodata', ''],
          ['Victoria', ''],
          ['Vienna', ''],
          ['Virginia', ''],
          ['Vorarlberg', ''],
          ['Wake County', ''],
          ['Warwickshire', ''],
          ['Washington', ''],
          ['Waterloo', ''],
          ['Weatherford', ''],
          ['Wellington', ''],
          ['Western Australia – NewSLIP', ''],
          ['Windsor', ''],
          ['Wyre Council', ''],
          ['Zaragoza', ''],
          ['Zurich', '']
        ]);
     
 
  var options = {
    //Put your color hex code here
    colors: ['#ff0000'] //eg. red
};
        
 
 
 
   var view = new google.visualization.DataView(data);
        view.setColumns([0, 1]);

      var options = {
          title: 'European Youthstart Network'
        };

   
     var chart = new 
google.visualization.GeoChart(document.getElementById('regions_div'));

     chart.draw(data, options);

       var selectHandler = function(e) {
         window.location = data.getValue(chart.getSelection()[0]['row'], 1 
);
        }

        // Add our selection handler.
        google.visualization.events.addListener(chart, 'select', 
selectHandler);
   }
 
    </script>
  </head>
  <body>
    <div id="regions_div" style="width: 900px; height: 500px;"></div>
  </body>
</html>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-visualization-api.
For more options, visit https://groups.google.com/d/optout.

Reply via email to