Jquery selects
Posted: Mon Jan 14, 2013 12:52 pm
I am trying to set/update a $_SESSION variable based on a radio button being clicked.
Code: Select all
<script type="text/javascript">
$(document).ready (function(){
$(':radio').change (function()
$(':radio[name=list]:nth(0)').attr('checked',true);
{
$_SESSION{'list'} = "Yes";
} else {
$_SESSION{'list'} = "No";
};
});
<input type="radio" name="list" value="Yes">Yes</input>
<input type="radio" name="list" checked value="No">No</input>
</script>