Get your own website Result Size: 625 x 565
x
 
<!DOCTYPE html>
<html>
<body>
<div id="myDiv" style="border-right:5px solid red;">This is a div element.</div>
<br>
<button type="button" onclick="myFunction()">Return right border</button>
<script>
function myFunction() {
  alert(document.getElementById("myDiv").style.borderRight);
}
</script>
</body>
</html>