I have a few checkboxes in my form and I need to change their value when the checkbox is checked.

For example this is one of the checkboxes:

```
<input type="checkbox" name="drink" value=""/>

```

I know `.val()` can change it but I wasn't able to do this with `if` statement.

I appreciate your answer in advance.