I'm using OpenLayers 2.13 and Postgresql 9.3 for my development activities. I want to load region data from database and load into openlayers.
Below result i'm getting from St_astext(geom) in postgresql 9.0 and above
"MULTIPOLYGON(((77.6620335903023 12.8381894855534,77.6620330917475 12.8384550503658,77.662583464913 12.8384554346975,77.6625831247336 12.8381894684868,77.66234257162 12.8381895285991,77.6622741102056 12.8381895459662,77.6620335903023 12.8381894855534)))"
But in postgresql 9.3 i'm getting the below result with height parameter while using St_astext(geom)
"MULTIPOLYGON ZM (((77.6620335903023 12.8381894855534 0 0,77.6620330917475 12.8384550503658 0 0,77.662583464913 12.8384554346975 0 0,77.6625831247336 12.8381894684868 0 0,77.66234257162 12.8381895285991 0 0,77.6622741102056 12.8381895459662 0 0,77.662033590 (...)"
Below is the OpenLayers code to featch the wkt format
var feature = new OpenLayers.Feature.Vector(new OpenLayers.Geometry.fromWKT("MULTIPOLYGON ZM (((77.6620330345526 12.8382017120463 0 0,77.6620403164933 12.8384556061155 0 0,77.6625840206627 12.8384543231982 0 0,77.6625747884884 12.8381889127371 0 0,77.6620330345526 12.8382017120463 0 0)))"), null,{
label : "TEST", irregular: true, cursor:'pointer', fontSize: "14px", fontFamily: "arial, monospace", fontWeight: "bolder", labelAlign: "cm", fillColor: "#9fdaef", fillOpacity: 0.3, strokeWidth:4, strokeColor: "#005596" });
I'm getting an error like below
TypeError: a.geometry.getBounds is not a function in OpenLayers.js (line 611, col 334)
By using Multipolygon without height parameter i can able to load region data in Openlayers
but, with the height parameter i can't.
Please guide me to load wkt value with height parameter in Openlayers.