Creaing a Pyramid shape using only CSS/HTML -
i trying create pyramid shape in css. i doing method read on internet when set width of div 0 px borders join creating 4 triangles. want remove/cut pointed tip of pyramid , have been unable it. tried hiding tip other div not looks right.
present shape: below have made far.
required shape: want make shape this:
here code:
#pyramid { width: 0px; border-left: 20px dotted transparent; border-right: 20px solid transparent; border-bottom: 50px solid blue; }
<div id="pyramid"></div>
adding width div trick. doing so, you'll in fact have 3 connected figures: 2 triangles , 1 rectangle in between.
#pyramid { width: 5px; border-left: 20px dotted transparent; border-right: 20px solid transparent; border-bottom: 50px solid blue; }
<div id="pyramid"></div>
Comments
Post a Comment