External CSS is called via the <link /> tag within the <head></head>.
The style sheet contains CSS syntax including if needed comment tags "/* */". The external style sheet has a document specification ".css" in our example we are calling in "default.css"
Example:
The style sheet contains CSS syntax including if needed comment tags "/* */". The external style sheet has a document specification ".css" in our example we are calling in "default.css"
Example:
HTML CODE:
CSS Syntax:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="EN" dir="ltr">
<head>
<title>External CSS Styles</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link rel="stylesheet" href="default.css" type="text/css" />
</head>
<body>
</body>
</html>CSS Syntax:
body{color:#FFFFFF; background-color:#000000;}
/* This is a comment */
p{font-family:Verdana, Arial, Helvetica, sans-serif;}
h1{font-size:16px;}| Website Design | Website Design Company | Web Development Get a beautiful website design. Studio Web is a results oriented web design & online marketing firm serving companies worldwide. |
Sponsored Link |
No comments:
Post a Comment