<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
<title></title>
</head>
<body text="#000000" bgcolor="#ffffff">
Code is now like that but pan and zoom are still visible.<br>
<i><br>
var map = new OpenLayers.Map(options);<br>
<br>
// Options<br>
<br>
var options = {<br>
controls: [],<br>
projection: new OpenLayers.Projection("EPSG:900913"),<br>
displayProjection: new OpenLayers.Projection("EPSG:4326"),<br>
units: "m",<br>
maxResolution: "auto",<br>
allOverlays: false,<br>
maxExtent: new
OpenLayers.Bounds(-75.86,44.05,-74.526,45.016).transform(new
OpenLayers.Projection("EPSG:4326"), new
OpenLayers.Projection("EPSG:900913")),<br>
stateId: "map",<br>
prettyStateKeys: true // for pretty permalinks<br>
<br>
};<br>
<br>
map.addControl(new OpenLayers.Control.ScaleLine());<br>
map.addControl(new OpenLayers.Control.Navigation());<br>
//map.addControl(new OpenLayers.Control.PanPanel());<br>
//map.addControl(new OpenLayers.Control.ZoomPanel());<br>
map.addControl(new OpenLayers.Control.Permalink('permalink'));</i><br>
<br>
<br>
Am 26.01.2011 18:49, schrieb Andrew Stewart:
<blockquote
cite="mid:94816848A8EB3941B1E8592F425827A981E5BD97DB@chex2.crdnet.ca"
type="cite">
<pre wrap=""> Try declaring your controls empty initially - controls: []
Then just add any control you want after
                map.addControl(new OpenLayers.Control.Whatever());
And I think your pan bar will not be there anymore.
-----Original Message-----
From: <a class="moz-txt-link-abbreviated" href="mailto:users-bounces@geoext.org">users-bounces@geoext.org</a> [<a class="moz-txt-link-freetext" href="mailto:users-bounces@geoext.org">mailto:users-bounces@geoext.org</a>] On Behalf Of Kai Volland
Sent: January 26, 2011 10:45 AM
To: <a class="moz-txt-link-abbreviated" href="mailto:users@geoext.org">users@geoext.org</a>
Subject: Re: [Users] Fwd: How to remove/hide Openlayers PanZoomBar
I added them this way:
controls: [
new OpenLayers.Control.ScaleLine(),
new OpenLayers.Control.Navigation(),
//new OpenLayers.Control.PanPanel(),
//new OpenLayers.Control.ZoomPanel(),
new OpenLayers.Control.Permalink('permalink')
],
Am 26.01.2011 18:31, schrieb Andrew Stewart:
</pre>
<blockquote type="cite">
<pre wrap="">Are you adding your map to a mappanel? When you declare your map variable set the controls to be
controls: []
-----Original Message-----
From: <a class="moz-txt-link-abbreviated" href="mailto:users-bounces@geoext.org">users-bounces@geoext.org</a> [<a class="moz-txt-link-freetext" href="mailto:users-bounces@geoext.org">mailto:users-bounces@geoext.org</a>] On Behalf Of Kai Volland
Sent: January 26, 2011 10:27 AM
To: <a class="moz-txt-link-abbreviated" href="mailto:users@geoext.org">users@geoext.org</a>
Subject: [Users] Fwd: How to remove/hide Openlayers PanZoomBar
Hi,
here is my very simple question:
How to remove or hide the PanZoomBar from Openlayers. It seems to be
added to the map automatically.
Removing only the zoom-buttons of this bar would be even better for me.
Kind regards
Kai
_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@geoext.org">Users@geoext.org</a>
<a class="moz-txt-link-freetext" href="http://www.geoext.org/cgi-bin/mailman/listinfo/users">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a>
[This message has been scanned for security content threats and viruses.]
[The City of Red Deer I.T. Services asks that you please consider the environment before printing this e-mail.]
_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@geoext.org">Users@geoext.org</a>
<a class="moz-txt-link-freetext" href="http://www.geoext.org/cgi-bin/mailman/listinfo/users">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a>
</pre>
</blockquote>
<pre wrap="">
_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@geoext.org">Users@geoext.org</a>
<a class="moz-txt-link-freetext" href="http://www.geoext.org/cgi-bin/mailman/listinfo/users">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a>
[This message has been scanned for security content threats and viruses.]
[The City of Red Deer I.T. Services asks that you please consider the environment before printing this e-mail.]
_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@geoext.org">Users@geoext.org</a>
<a class="moz-txt-link-freetext" href="http://www.geoext.org/cgi-bin/mailman/listinfo/users">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a>
</pre>
</blockquote>
<br>
</body>
</html>