I have the following html:
<input type="checkbox" name="email" /> Email
Elsewhere in my code, I need to change this checkbox to check and also change the description, like so:
<input type="checkbox" name="email" checked /> Email (enabled)
I've tried:
$('input[name=email]').val('test');
But that doesn't change the text. How do I mark it checked and also change the text?