<input name="box1" type="checkbox" id="box1" value="1" onClick="document.getElementById('box2').checked=! this.checked;">
<input name="box2" type="checkbox" id="box2" value="2" onClick="document.getElementById('box1').checked=! this.checked;">