HTML CSS examples for CSS Widget:Div
Create div above and cover its parent's border
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> .line {<!-- ww w .ja va 2s .co m--> height:11px; border-bottom:2px solid Chartreuse; text-align:center; } .title { display:inline-block; padding:0 6px; background:white; margin-top:-3px; } </style> </head> <body> <div class="line"> <div class="title"> Lorem i </div> </div> </body> </html>