<html>
<body>
<div id="myDiv" style="border-left:thick solid green">This is a div element.</div>
<br>
<button type="button" onclick="myFunction()">Return left border color</button>
<script>
function myFunction() {
alert(document.getElementById("myDiv").style.borderLeftColor);
}
</script>
</body>
</html>