title: How to get a value of JSF selectBooleanCheckbox by using JavaScript?
body: <p>I save in my selectBooleanCheckbox only boolean values in a backingbean which named "bean". To set a label for this checkbox in my JSF xhtml page i´m using a JSF outputText component. </p>
  
  <p>Here is the JSF code (they are 2 checkboxes in this example):</p>
  
  <pre><code>&lt;h:selectBooleanCheckbox class="extern" value="#{bean.booleanValue1}" /&gt;
  &lt;h:outputText value="My Labeltext1"/&gt;
  
  &lt;h:selectBooleanCheckbox class="extern" value="#{bean.booleanValue2}" /&gt;
  &lt;h:outputText value="My Labeltext2"/&gt;
  </code></pre>
  
  <p>Now i want to get the selected checkboxes with java script. I´m using the onselect event:</p>
  
  <pre><code>&lt;h:selectBooleanCheckbox class="extern" value="#{bean.booleanValue1}" onselect="MyObject.update(this.options[this.selectedIndex].text);"/&gt;
  &lt;h:outputText value="My Labeltext1"/&gt;
  
  &lt;h:selectBooleanCheckbox class="extern" value="#{bean.booleanValue2}" onselect="MyObject.update(this.options[this.selectedIndex].text);"/&gt;
  &lt;h:outputText value="My Labeltext2"/&gt;
  </code></pre>
  
  <p>But this gets only the boolean values of the selected checkboxes. Is it possible to get the value of the outputText components? Is tehre any way to connect the output component with the selectBooleanCheckbox component?</p>