Since each of the four borders can have a different color, .css('border-color') cannot work, which color to return (even if they are all the same).
In most cases, the color of all borders is the same, so you can do this as follows:
$('div.divIm').mouseover(function() { var borderColor = $(this).css('border-left-color'); debugger; });
So, you get the color of the left border, and this should be enough for your needs.
davehauser
source share