[OpenLayers-Users] Overlayed div on the map
goliah
bianchimro at gmail.com
Thu Feb 5 10:14:03 EST 2009
Hi Alexander,
your hint helped me a lot. I didn't know the inner structure of the map div.
What I did was simply inserting the div into the map.viewPortDiv.
The important thing is setting the right css attributes for the overlayed
div:
position:asolute;
and set z-index to map.Z_INDEX_BASE['Popup']-1
I've used jquery, but I think it could be accomplished with plain js or
OpenLayers Utils.
here is the result (works fine):
http://www.maurob.org/webrsa/
(in this case i am working on, the map is themed dinamically using a feature
attribute and the legend is created automatically)
Thanks!
Mauro
Alexandre Dube wrote:
>
> Hi,
>
> I just checked Map.js. Maybe you could use some of its methods to create
> a div and add it to you map.viewPortDiv the same way other Openlayers
> div are added to the map viewport.
>
> Just an idea...
>
> Best of luck,
>
> Alexandre
>
> goliah wrote:
>> Dear all,
>>
>> I'd like to superimpose a div on the map (for showing a legend in my
>> case).
>> Do you know any smart way to do it?
>> Actually I'm using html/css for this, but I'd prefer an OpenLayers
>> method,
>> if possible.
>>
>> Thanks a lot
>>
>> Mauro
>>
>
>
> --
> Alexandre Dubé
> Mapgears
> www.mapgears.com
>
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>
>
--
View this message in context: http://n2.nabble.com/Overlayed-div-on-the-map-tp2274000p2275336.html
Sent from the OpenLayers Users mailing list archive at Nabble.com.
More information about the Users
mailing list