How to get the selected option from p:selectOneRadio using javascript
How do you get which radio is selected within p:selectOneRadio using javascript/jquery ? Since the p:selectOneRadio uses no radio tags I have no idea how to get the checked option using CSS selectors. <p:selectOneRadio onchange="reactToChangedRadio()" > <f:selectItem itemLabel="....." itemValue="..." /> <f:selectItem itemLabel="....." itemValue="..." /> <f:selectItem itemLabel="....." itemValue="..." /> </p:selectOneRadio> You can use the jquery solution or choose a simple javascript solution: document.getElementById("myFormId:mySelectId")[0].checked See the post from CodeRanch: http://www