Monday, July 11, 2011

Introduction to CSS

Using CSS, or Cascading Style Sheets you can completely separate text displayed on Web Page(which is created in HTML code) and information that describes CSS. CSS help you save time.


Example:
Let's get started with using style sheets. CSS data is actually plain text written in a specific way. Let's take a look at the contents of a sample CSS file:


Copybody
{
font-family: Verdana;
font-size: 9pt;
text-align: right;
}
div
{
font-family: Georgia;
}
.important
{
background-color: #ffffde;
border: thin black ridge;
font-family: Franklin Gothic Book;
}
It is actually completely readable – this style sheet






Here are the elements that would be affected by the sample CSS file.


<html>
...
<body>
Body text goes here. Lorem ipsum dolor sit amet.
<div>Div text goes here. This text is written in a different font.</div>
Body text continued.
<div class="important">This is very important!</div>
Body text continued. Lorem ipsum dolor sit amet, consectetur adipisicing elit.
</body>
</html>

No comments:

Post a Comment

Open default email app in .NET MAUI

Sample Code:  if (Email.Default.IsComposeSupported) {     string subject = "Hello!";     string body = "Excellent!";    ...