I have a set of KML files hosted on a webserver, which two applications use; one uses OpenLayers and one uses Google Maps.

The problem is the order they render the KML. Google Maps (and Google Earth) renders the first linestring in the KML as the top layer. However, OpenLayers places the first one underneath, with later linestrings appearing on top of it.

Hence the same KML file looks different depending on which application is displaying it.

Is there anyway to choose which object appears on top in OpenLayers?

The code which adds the KML to the map is:

```
function routeMap_addKML (label, kmlurl, show) {

var layer = new OpenLayers.Layer.Vector(
        label,
        {
          strategies: [new OpenLayers.Strategy.Fixed()],
          protocol: new OpenLayers.Protocol.HTTP({
            url: kmlurl,
            format: new OpenLayers.Format.KML({
              extractStyles: true, 
              extractAttributes: true,
              maxDepth: 2
            })
          }),
          'onFeatureInsert': function () { reScaleMap(routeMap); }
        }
      )

      layer.setVisibility(show);
      routeMap.addLayer(layer);

return layer;

}

```