How can you apply CSS style using ID value? ( ASP.NET CSS interview questions with answers)
So let’s say you have a HTML paragraph tag with id “mytext” as shown in the below snippet.
<p id="mytext">This is HTML interview questions.</p>
You can create a style using “#” selector with the “id” name and apply the CSS value to the paragraph tag. So to apply style to “mytext” element we can use “#mytext” as shown in the below CSS code.
<style>
#mytext
{
background-color:yellow;
}
</style>
http://
http://www.questpond.com/
Contributed by:
Shivprasad koirala Koirala
I am a Microsoft MVP for ASP/ASP.NET and currently a CEO of a small
E-learning company in India. We are very much active in making training videos ,
writing books and corporate trainings. Do visit my site http://www.questpond.com for
.NET, C# , design pattern , WCF , Silverlight , LINQ , ASP.NET , ADO.NET , Sharepoint , UML , SQL Server training and Interview questions and answers
Resourse address on xpode.com
http://www.xpode.com/Print.aspx?Articleid=691
Click here to go on website
|