OpenLayers.Control.Button - OpenLayers

# OpenLayers.Control.Button

The Button control is a very simple push-button, for use with OpenLayers.Control.Panel. When clicked, the function trigger() is executed.

#### Inherits from

- OpenLayers.Control

#### Use

>     var button = new OpenLayers.Control.Button({
>         displayClass: "MyButton", trigger: myFunction
>     });
>     panel.addControls([button]);

Will create a button with CSS class MyButtonItemInactive, that will call the function MyFunction() when clicked.

The Panel control is a container for other controls.
Controls affect the display or behavior of the map.
Close