Last active
December 11, 2015 04:28
-
-
Save yicui/4545081 to your computer and use it in GitHub Desktop.
A simple step-by-step example of webpage styling
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Webpage Styling</title> | |
<meta http-equiv="content-type" content="text/html; charset=utf-8" /> | |
<meta name="keywords" content="web, CSS, styling, div" /> | |
<meta name="description" content="A simple step-by-step example of webpage styling" /> | |
<style> | |
#header { | |
background-color:red; | |
} | |
.lists { | |
text-align:center; | |
} | |
p { | |
font-family:arial; | |
background-color:yellow; | |
font-size:1.2em; | |
color:blue; | |
} | |
</style> | |
</head> | |
<body> | |
<h1 id="header">Special Topics on Web Development</h1> | |
<p>In this webpage you can find main course materials of this course </p> | |
<div> | |
<h2>Lecture Notes</h2> | |
<p>This section contains all lecture notes | |
<ul class="lists"> | |
<li>Lecture 1</li> | |
<li>Lecture 2</li> | |
</ul> | |
</div> | |
<div> | |
<h2>Assignments</h2> | |
<p>This section contains all assignments | |
<ol class="lists"> | |
<li>Assignment 1</li> | |
<li>Assignment 2</li> | |
</ol> | |
</div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Original Gist: webpage with no styles
1st Revision:
style
attributes added to individual tags2nd Revision: styling instructions concentrated to the
<style>...</style>
tag pair