Skip to main content

Example CSS file

Example CSS file

Add the following in the Head section of your web page
<link href="default.css" rel="stylesheet" type="text/css" />do necessary modification
save the code below in a file name default.css and see the result

*{
 margin: 0;
 padding: 0;
}

body {
 margin: 20px 0;
 background: #FFFFFF;
 font: normal 13px Arial, Helvetica, sans-serif;
 color: #666666;
}

a {
 color: #29A3E1;
}

a:hover {
 text-decoration: none;
 color: #E16629;
}

/* Boxed */
.title {
 background: url(images/img4.gif) no-repeat right center;
 border-bottom: 3px solid #CFCFCF;
}

.boxed1 .title {
 font: bold 100% "Trebuchet MS", Arial, Helvetica, sans-serif;
}

.boxed1 .content {
 background: url(images/img05.gif) no-repeat left bottom;
 padding: 20px;
}

.boxed2 .title {
 font: normal 182% "Trebuchet MS", Arial, Helvetica, sans-serif;
}

.boxed2 .content {
 background: url(images/img06.gif) repeat-x left bottom;
 padding: 20px;
}

.boxed3 .title {
 font: normal 129% "Trebuchet MS", Arial, Helvetica, sans-serif;
}

.boxed3 .content {
 padding: 20px;
}

.boxed3 ol, .boxed3 ul {
 margin-left: 1em;
}


/* Header */
#header {
 width: 760px;
 height: 161px;
 margin: 0 auto;
 background: url(images/img02.jpg) no-repeat 100% 50px;
 border-bottom: 5px solid #E16629;
}

/* Logo */
#logo {
 float: left;
 width: 240px;
 height: 160px;
 background: #29A4E1 url(images/img01.gif) no-repeat;
 text-align: center;
}

#logo h1 {
 padding-top: 80px;
 font: bold 36px Georgia, "Times New Roman", Times, serif;
}

#logo h2 {
 font: bold 11px Verdana, Arial, Helvetica, sans-serif;
}

#logo a {
 text-decoration: none;
 color: #FFFFFF;
}

/* Menu */
#menu {
 float: left;
 width: 520px;
 height: 50px;
 background: #F4F4F4;
}

#menu ul {
 height: 5px;
 background: #29A4E1;
 list-style: none;
}

#menu li {
 display: inline;
}

#menu a {
 display: block;
 float: left;
 height: 30px;
 padding: 15px 15px 0 15px;
 border-top: 5px solid #29A4E1;
 text-decoration: none;
 font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
 font-weight: bold;
 color: #000000;
}

#menu a:hover {
 background: #DCDCDC;
 border-top-color: #1A7196;
}

#menu .active a {
 background: #FFA800;
 border-top-color: #E16629;
}

#menu a b {
 text-decoration: underline;
}

/* Page */
#page {
 width: 760px;
 margin: 0 auto;
 background: url(images/img03.gif) repeat-y;
 border-top: 1px solid #FFFFFF;
 border-bottom: 1px solid #FFFFFF;
}

/* Content */
#content {
 float: right;
 width: 480px;
 padding: 20px;
 border-bottom: 1px solid #FFFFFF;
}

#content p, #content ol, #content ul {
 line-height: 152%;
}

/* Sidebar */
#sidebar {
 float: left;
 width: 200px;
 padding: 20px;
}

/* News */
#news {
 padding-top: 10px;
 padding-bottom: 0;
}

#news ul {
 list-style-type: square;
}

#news li {
 margin-bottom: 15px;
}

#news h3 {
 margin-bottom: 10px;
 font-size: 92%;
}

#news h3 a {
 display: block;
}

#news p {
 font-size: 85%;
}

/* Welcome */
#welcome {
 margin-bottom: 20px;
}

/* Samples */
#sample1, #sample2 {
 float: left;
 width: 230px;
}

#sample1 {
}

#sample2 {
 margin-left: 20px;
}

/* Footer */
#footer {
 width: 760px;
 margin: 0 auto;
 padding: 20px 0;
 border-top: 5px solid #E16629;
}

#footer p {
 text-align: center;
 font-size: 77%;
}

Comments

Popular posts from this blog

MSW Logo

Start Logo and type the following command. cs for [j 1 9 1][rt 45 for [i 1 15 1] [repeat 60[lt 6 fd :i]]] Output :

Multimedia and Web Technology (Code 067)

Multimedia and Web Technology (Code 067) Learning Objectives: 1. To get proficient in WEB Development using HTML/XML 2. To be able to write server & client scripts. 3. To get proficient in Web Management 4. To get proficient in creating Web Site 5. To design Graphical images using Image-Editing tools 6. To get proficient in audio & video capture and editing using software tools 7. To create and publish a self-contained multimedia CD-ROM using multimedia authoring tool 8. To develop ability to use the Open Source Technology. 9. To develop ability to localize software applications. Competencies: The student will become proficient in the following: 1. Managing Self Developed web-site 2. Management of a full-fledged web portal 3. Creation & Editing of graphical images. 4. Capturing, Creating and Editing Audio and Video through external devices. 5. Embedding images & video into a presentation. Class XI (Theory) Duration: 3 hours Total Marks: 70 Unit No.

CSS Properties

margin : length or percentage or auto;   margin-top a:link list-style margin-left a:visited list-style-image margin-right a:hover list-style-image-position margin-bottom a:focus list-style-image-type padding-top : length or percentage Css Anchor, Link height padding-left a.column1:link line-height padding-right Css Border max-height padding-bottom border min-height color : red or #2398 or rgb(,,) border-style max-width letter-spacing : normal or length border-width min-width text-align: left or center or right or justify border-bottom Css Classification text-decoration: underline or overline or line through or blink border-bottom-color clear text-indent : length or percentage border-bottom-style cursor text-transform: none or capitalize or lowercase border-bottom-width display white-space: normal or pre or nowrap border-right float word-spacing: normal or length border-right-color overflow Font border-right-style visibility font border-right-width z-index font-fami