HTML CSS examples for CSS Widget:Div
Add arrow on top of div
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> .box {<!--from w ww .j a v a2 s . c om--> width:201px; height:201px; margin:51px; background:red; } .box:before { content:""; width:0; height:0; border-left:6px solid Chartreuse; border-right:6px solid yellow; border-bottom:6px solid blue; position:relative; top:-24px; left:11px; } </style> </head> <body> <div class="box"></div> </body> </html>