0
How to change color for <progress>?
8 Antworten
+ 8
progress {
height: 15px;
border: 0px none;
background-color: grey;
color: red;
}
progress::-webkit-progress-bar {
background-color: grey;
}
progress::-webkit-progress-value {
background-color: red;
}
progress::-moz-progress-bar {
background-color: red;
}
taken from:
http://ankitjain.info/ankit/2013/08/15/html5-progress-bar-css-firefox-chrome-animation/
+ 6
try
progress {
height: 15px;
border: 0px none;
background-color: grey;
color: red;
}
progress::-webkit-progress-bar {
background-color: grey;
}
progress::-webkit-progress-value {
background-color: lime; /* change this */
}
progress::-moz-progress-bar {
background-color: red;
}
0
it's don't work.
0
more precisely, it's work wrong. Color changing, but just on value red and grey background, and doesn't matter what colours you input
0
value green
0
progress {
height: 15px;
border: 0px none;
background-color: grey;
color: red;
}
progress::-webkit-progress-bar {
background-color: grey;
}
progress::-webkit-progress-value {
background-color: red;
}
progress::-moz-progress-bar {
background-color: red;
}
taken from:
http://ankitjain.info/ankit/2013/08/15/html5-progress-bar-css-firefox-chrome-animation/
it works, but just if i write under
progress {
background-color: *color*
}
and doesn't matter what the color.
0
Use inline style="background-color:{{yourColor}}" attribute.It just works. Edit: You're right indeed,it only changes to green.Maybe something problem on sololearn.