Hi list,
I'm showing some vector features on my map, which come from a GeoJson file.
In this GeoJson, features have an id, which is not a standard attribute ...
for instance:
{
"type": "Feature",
"id": "1",
"geometry": {
"type": "Point",
"coordinates": [613100, 2003000]
},
"properties": {
"post80": "true",
"precise": "true"
}
}
As a result, OL features inherit this id as a "fid" property.
For some reason, I have to clone these features.
I was surprised to see that "fid" property is not copied (it becomes "null"
in the cloned feature).
The reason lies around line 100 in Vector.js :
* Method: clone
* Create a clone of this vector feature. Does not set any non-standard
properties.
I guess I have no other solution to move the id parameter inside the geojson
"properties" object.
F.
_______________________________________________
Users mailing list
[email protected]
http://openlayers.org/mailman/listinfo/users