skip to Main Content

On click button Check and Uncheck multiple radio buttons via Jquery

As per the image I want to check and uncheck radio button as all present and all absent. I have written some code but it works only once. $(document).on('click', '#btn_all_absent', function(e){ $("input:radio[class^=present]").each(function(i) { $(this).attr('checked',false); }); $("input:radio[class^=absent]").each(function(i) { $(this).attr('checked',true); }); });…

VIEW QUESTION

Data pass to codeigniter to ajax the function not working – Jquery

I try to pass a data code igniter controller to ajax request the written function not working Controller public function selectPlaygrounds() { $data = $this->branchatm->getCitiesFromState($state); $result=''; if($data){ foreach($data as $list){ $result.="<li ng-click='sawAll($list->city);'>$list->city</li>"; } } sendJsonResponse($result); } Ajax call $.ajax({ 'method':…

VIEW QUESTION
Back To Top
Search