How can I call a Javascript event on a HTML div border corners?

Joe Burnett

New member
It sounds confusing, but is quite simple. I have a square div, and using css I have four circles replacing the corners of the of the divs border. I want the user to be able to click on one of the corner circles changing the curser image and calling the Javascript onclick event. How do I did that?
 
Never done this so I'm guessing here but my first port of call would be to place a div with set width and height over the circles and then use an onclick event with JavaScript.

So the code would look like

<script type="text/javascript">
function testing()
{
//code to be run
}
</script>

<div style="width:10px; height:10px;" onclick="testing()"></div>
 
Back
Top