Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How would you place a 'required asterisk' image in front of the first letter of a label using only css?

Tags:

html

css

Is it possible to place a 'required asterisk' image in front of the first letter of a label only using css? The text of the label is right aligned, so there is a varying length of space in front of the text of each label.

like image 536
coder Avatar asked Jan 06 '12 23:01

coder


1 Answers

.foo:before {
    content : "* ";
    color   : red;
}
like image 91
Nobody Avatar answered Sep 28 '22 00:09

Nobody