Javascript examples for CSS Style Property:borderLeft
Set the width, style and color of the left border of a <div> element:
<!DOCTYPE html> <html> <head> <style> #myDiv {//from w ww.ja v a 2 s . com border: thick solid blue; } </style> </head> <body> <div id="myDiv">This is a div element.</div> <br> <button type="button" onclick="myFunction()">Change left border</button> <script> function myFunction() { document.getElementById("myDiv").style.borderLeft = "thin dotted red"; } </script> </body> </html>