I'm doing a map where I draw a feature by using the DrawFeature control and then store it in a DB as WKT. Then I'm calling the feature back by quering the DB and parsing the WKT string to a feature. Works correctly with Firefox and Chrome but the vector renders shifted few meters and rotated in Internet Explorer (both IE7 and IE8). I does not matter if in witch browser I draw the feature, the WKT saves correctly and the same way from IE and Firefox. But when rendering the feature back IE gets it wrong. I have projection suspected but can't find anything wrong, the map has EPSG:3057. I do harvest the bounds from the feature after reading it from WKT and all browsers zoom in and set center correctly.
Here's an image to illustrate the problem: http://farm3.static.flickr.com/2470/4034630696_b41e6b3b9c_o.jpg Here's how I'm reading and inserting the feature: //Create an array of features from WKT var wkt = new OpenLayers.Format.WKT(); arr = new Array(wkt.read(xmlHttp.responseText)); // Create a vector feature from wktArray (only one element for LINESTRING used here) var feat = new OpenLayers.Feature.Vector(); feat = wkt.read(xmlHttp.responseText);//arr[0]; // Add feature to Drawings layer getLayerByName("Drawings").addFeatures([feat]); // Lets zoom down to the feature var drawingBounds = new OpenLayers.Bounds(); drawingBounds = feat.geometry.getBounds(); map.zoomToExtent(drawingBounds); map.setCenter(drawingBounds); Thanks! Hrannar Hauksson [email protected] -- View this message in context: http://n2.nabble.com/Vector-feat-from-WKT-fucked-up-in-IE-but-fine-in-Firefox-and-Chrome-tp3871781p3871781.html Sent from the OpenLayers Dev mailing list archive at Nabble.com.
_______________________________________________ Dev mailing list [email protected] http://openlayers.org/mailman/listinfo/dev
