Is it possible to add a popup (without a marker icon) to a Vector (LineString)?
This is my code, if possible, how to change it to add the popup? I need the popup to display some additional information to the road segement.
<script>
var ytrajectory=[];
ytrajectory.push('LINESTRING (11.1119339 46.0772706, 11.1117177 46.077171, 11.111613 46.0770837, 11.1115376 46.07702)');
ytrajectory.push('LINESTRING (11.1115376 46.07702, 11.1114585 46.0768611, 11.1114219 46.0767673)');
...
</script>
function showReconstructedTrajectoryy() {
var vectorLayer = new OpenLayers.Layer.Vector(
"Reconstructed trajectoryy", {
style : reconstructedTrajectoryStyleYellow
});
var parser = new OpenLayers.Format.WKT();
var src = new OpenLayers.Projection('EPSG:4326');
var dest = new OpenLayers.Projection('EPSG:900913');
var s, wktLine, features, reprojectedFeatures;
for (s = 0; s < ytrajectory.length; s++) {
wktLine = ytrajectory[s];
features = parser.read(wktLine);
reprojectedFeatures = features.geometry.transform(src, dest);
vectorLayer.addFeatures(new OpenLayers.Feature.Vector(
reprojectedFeatures));
}
osmmap.addLayer(vectorLayer);
osmmap.zoomToExtent(vectorLayer.getDataExtent());
}