Will any DP member please explain how to draw a line from a point to another in HTML with the script? Because I have to draw a right angled triangle in my educational site.
drhowarddrfine is correct, and you'd still have to use Javascript within the canvas. Your other "cheating" alternative is to use a table (with CSS) or a <div> also with CSS and an image for the angled line. You set the <div> as a retangle with the height and length you need, and activate the borders for the bottom and side: .mytriangle{ width: 100px; height: 100px; border-left: 1px solid #000; border-bottom: 1px solid #000; } Within the table cell or your div, you than place a picture with the connecting angled line. You might want to put it in the background: .mytriangle{ background: url(http://... adress of the image here)left top repeat-none; } It's cheating, but it will work. good luck.