I have used vector point from database and also polygon country vectors from database.Points appear with in this country vectors but as I switch to google earth map as base layer the points at smaller zoom level would appear outside boundary where as at other zoom level it would appear inside. I have tried to add projection too but in vain.Do I need to reproject google earth's base layer and How?
map = new OpenLayers.Map('map', {
controls: [
new OpenLayers.Control.Navigation(),
new OpenLayers.Control.PanZoomBar(),
new OpenLayers.Control.LayerSwitcher({'ascending':false}),
new OpenLayers.Control.ScaleLine(),
new OpenLayers.Control.MousePosition(),
new OpenLayers.Control.OverviewMap(),
new OpenLayers.Control.KeyboardDefaults()
],
projection: new OpenLayers.Projection("EPSG:900913"),
displayProjection: new OpenLayers.Projection("EPSG:4326"),
numZoomLevels: 21,
maxExtent: new OpenLayers.Bounds(-20037508, -20037508,20037508, 20037508.34)
});
var border = new OpenLayers.Layer.WMS( "Border",
url,
{layers: 'GisData:BORDER'}
);
var dsBand = new OpenLayers.Layer.WMS( "District Band",
url,
{layers: 'GisData:BND'}
);
var Site1 = new OpenLayers.Layer.WMS( "Site 1",
url,
{layers: 'GisData:sites', transparent: "true",format: "image/png"}
);
dwnSite3G.setIsBaseLayer(false);
var Site2 = new OpenLayers.Layer.WMS( "Site 2",
url,
{layers: 'GisData:sites2', transparent: "true",format: "image/png"}
);
var g_pmap = new OpenLayers.Layer.Google(
"Google Physical",
{type: G_PHYSICAL_MAP}
);
var gmap_gs = new OpenLayers.Layer.Google(
"Google Streets" // the default
);
var gmap_ghy = new OpenLayers.Layer.Google(
"Google Hybrid",
{type: G_HYBRID_MAP}
);
var gmap_gsat = new OpenLayers.Layer.Google(
"Google Satellite",
{type: G_SATELLITE_MAP}
)