<script>
function changeBorders(){
document.getElementById('a').style.borderTop='1px solid black';
document.getElementById('a').style.borderBottom='1px solid black';
document.getElementById('a').style.borderLeft='1px solid black';
document.getElementById('a').style.borderRight='1px solid black';
}
</script>
<div id='a' onClick='changeBorders();'>
Mohsen Haeri
</div>