<script>
function checkBox(inTextBox) {
var boxId = inTextBox.id;
if(boxId == "box1") {
document.getElementById("box2").value = "";
}else if(boxId == "box2"){
document.getElementById("box1").value = "";
}
}
</script>
<input type="text" id="box1" onblur="checkBox(this)"/>
<input type="text" id="box1" onblur="checkBox(this)" />