# RadioButton

var cars = ["Saab", "Volvo", "BMW"]; onRadioCLick = function (selection) { alert("You selected: " + selection) } var radioButton = new innovaphone.ui1.RadioButton("position:absolute; left:50px; top:50px", "RadioButton", cars, onRadioCLick, "Volvo", true); out.appendChild(radioButton.container);

## innovaphone.ui1.RadioButton(container, groupName, elements, funcOnClick, vertical)

Creates a radio button group with an on click function

Arguments:

container
  HTML element into which the button is placed. If undefined a span element is created#
groupName
  The of the group for tha radio button
[funcOnClick(element)]
  On click handler. The selected element name is returned
elements
  Array of the elements to be added to the radio control
vertical
  If is true the radio controls will be arranged on the vertical. Otherwise they wll be arranged on the horizontal

Public functions:

container
  get the container
getSelected()
  return the name of selected element