CSS triangle :before element
I’m using bootstrap, trying to make a div have a CSS triangle before it.
Here is my non-working code:
The way I’d like it to look is for there to be a pink left-pointing triangle right before the text “this”, with no gap between it and the div. I’ve tried to do this by floating the elements also, with no success.
You need to specify the
For positioning, add
position:relative to the parent, and then absolutely position the arrow
-15px to the left.