What did I do wrong? I followed my teacher but it didn't turn out correctly.
Filename: rb_validate.css
*/
/* Validation Styles */
input:focus, select:focus, textarea:focus {
background-color: rgb(255, 255, 180);
}
input#nameBox:focus:valid,
input#phoneBox:focus:valid {
background-color: rgb(220, 255, 220);
url(../images/rb_okay.png) right/contain no-repeat;
}
input#nameBox:focus:invalid,
input#phoneBox:focus:invalid {
background-color: rgb(255, 230, 230);
url(../images/rb_warning.png) right/contain no-repeat;
}
Save your changes to the file and then go to the rb_validate.css file in your editor to add validation styles for the web form.
Within the Validation Styles section, add the following style rules:
a. A rule that displays input, select, and textarea elements that have the focus with a background color of rgb(255, 255, 180).
b. A rule that displays the nameBox and phoneBox controls that have the focus and contain valid data with a background color of rgb(220, 255, 220) and the background image file.
c. A rule that displays the nameBox and phoneBox controls that have the focus and invalid data with a background color of rgb(255, 230, 230) and the background image file rb_warning.png at the right with no tiling contained within the background.