How to add CSS styles Styles to Elements with Particular
Attributes?
Answer Posted / swapna
The style rule below will match all input elements that has
a type attribute with a value of "text"
Input[type="text"] {background-color: blue}
id Selector
Defining styles for HTML elements with the id selector. The
id selector is defined as a #.
The style defined below will effect the element that has an
id attribute with a value of "green? ie., id=?green?
Ex: #green {color: green}
The style rule below will match the p element that has an
id with a value of "para1? ie., <p id=?para1?>
p#para1
{
text-align: center;
color: red
}
Do NOT start a class name or ID name with a number
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
What is factory method in design pattern?
Why have we declared the instance reference volatile?
What is the difference between 3 tier and n tier architecture?
What is aop design?
Where should we use singleton design pattern?
Can we have this pattern implemented using static class?
Write the code for a singleton class?
What are the examples of the behavioral design patterns?
Can we use an equated value as operands for an MVC ? Reason for the same.
What is the difference between architecture and design?
Are you using singleton in your code?
Which design pattern is mvc?
Can we inherit singleton class?
Is singleton bean thread safe?
What is meant by design pattern?