
      var SerialIco = new GIcon();
      SerialIco.image = "../img/googleearth/gmap_serial.png";
      //SerialIco.shadow = "fingershadow.png";
      SerialIco.iconSize = new GSize(12, 12);
      //SerialIco.shadowSize = new GSize(36, 34);
      SerialIco.iconAnchor = new GPoint(6, 6);
      SerialIco.infoWindowAnchor = new GPoint(6, 2);
      SerialIco.infoShadowAnchor = new GPoint(6, 2);
      //SerialIco.transparent = "fingertran.png";
      //SerialIco.printImage = "fingerie.gif";
      //SerialIco.mozPrintImage = "fingerff.gif";
      

function createSerialMarker(point, name, myurl) 
{
        var marker = new GMarker(point, {icon:SerialIco, title:name});
        GEvent.addListener(marker, "click", function() 
        {
        location.href = myurl;
        }); 

        return marker;
}

function CreateCtzMap(inputString)
{
  var map = new GMap2(document.getElementById("ctz_map"));
  map.addControl(new GSmallZoomControl);
  map.addControl(new GMapTypeControl(),(new GControlPosition(G_ANCHOR_BOTTOM_RIGHT, new GSize(5,16))));
  map.addMapType(G_PHYSICAL_MAP);
  map.setMapType(G_PHYSICAL_MAP);

  // ==== It is necessary to make a setCenter call of some description before adding markers ====
  // ==== At this point we dont know the real values ====
  map.setCenter(new GLatLng(0,0),0);

  // ===== Start with an empty GLatLngBounds object =====     
  var bounds = new GLatLngBounds();
  // ===== read the string, split it, get the lat/lon values
  var myStringList = inputString.split('|'); // split on commas
  for (var j = 0; j<myStringList.length; j=j+4)
  {
    // Add the comma delimited point to the bounds
    var point = new GLatLng(myStringList[j],myStringList[j+1]);
    var name = myStringList[j+2];
    var myurl = "http://dalky.cz/cteni/c-" + myStringList[j+3] + ".html";
    var myicon = SerialIco;

    // create the marker
    var marker = createSerialMarker(point,name,myurl);
    map.addOverlay(marker);
    bounds.extend(point);
  }

  // ===== determine the zoom level from the bounds =====
  var zoom = (map.getBoundsZoomLevel(bounds));
  map.setZoom(zoom);
  // ===== determine the centre from the bounds ======
  map.setCenter(bounds.getCenter());
}

