[OpenLayers-Users] moving panzoombar?
Imran Rajjad
rajjad at gmail.com
Mon Aug 2 08:51:38 EDT 2010
hi,
I kind of acheived what i was trying to do but puting the panZoom in
an external div and then assigning top and right (instead of left) to
that div, it worked for me but I will certainly this.
i put this in my main div
<div id="panZoomCont" style="position:absolute;top:125px;right:0px"></div>
-----------
inside init()
new OpenLayers.Control.PanZoomBar({'div':OpenLayers.Util.getElement('panZoomCont')}),
-----------
then somewher at the end of a page a script tag containing
// overwrite the hardcoded container div position set in panZoomBar.js
document.getElementById('panZoomCont').style.left="";
document.getElementById('panZoomCont').style.right="45px";
document.getElementById('panZoomCont').style.top="125px";
I wonder if its ok.comments and suggestions are welcome/
regards,
Imran
On Mon, Aug 2, 2010 at 4:36 PM, Arnd Wippermann <arnd.wippermann at web.de> wrote:
> Try this
>
> map.addControl( new OpenLayers.Control.PanZoomBar(), new
> OpenLayers.Pixel(300,0) );
>
> Arnd
>
> -----Ursprüngliche Nachricht-----
> Von: users-bounces at openlayers.org [mailto:users-bounces at openlayers.org] Im
> Auftrag von Imran Rajjad
> Gesendet: Montag, 2. August 2010 11:56
> An: <users at openlayers.org>
> Betreff: [OpenLayers-Users] moving panzoombar?
>
> Hi list,
>
> I have been looking around in user discusion list and cannot find a way to
> repoistion the pan zoom bar, I`m trying to align it with the right side of
> map instead of left. Now i did this through firebug by changing the style.
> but those variables seem to be coming out of some js file instead of css
> class. is there anyway to overwrite the hardcoded position?
>
> regards,
> Imran
>
> --
> I.R
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>
>
--
I.R
More information about the Users
mailing list