I want to validate radio button, when i checked radio button textbox will be disabled, but it cant happens. what will be the exact js for validate radio button.
My JS code is :
function selection_project_phd() { var phds = document.getElementById('EmployeeGuidedProjectPhd').value; var projs = document.getElementById('EmployeeGuidedProjectProject').value; var course_name = document.getElementById('EmployeeGuidedProjectCourseName').value; if(phds == 1) { course_name.disable=true; return false; } else if(projs==0) { course_name.disable=false; return false; } return true; }This one is View file .ctp code
Phd Project