Hello everybody,
I am to create web application where you define clickable parts of image (for the beginning lets talk just about rectangular - first click = left upper corner, second click = right down corner - after i am supposed to make circle or just a small point).
My question is how to get relative (to an image) coordinates of clicked points into variables x and y ?

BTW - my tool should be able to upload picture and define clickable areas of optional shape (rectangular, circle, point). I am not quite sure if javascript is for that purpose the best one (PHP or Java is mabey better?), but I would like to use Javascript the most i can.
thanks in advance Tad