Tự học HTML và CSS trong 1 giờ - part 8 - Pdf 16

ptg
1. Optionally, register a domain name. If you want your website to appear at a URL
like mycoolsite.com or mycompany.com, you need to register that domain name if
you haven’t already. There are a number of domain registrars, just enter domain
registration in your favorite search engine to see a large number of ads and search
results for companies that offer domain registration.
2. Pick out a web hosting company and sign up for an account. It may be the case
that you don’t need to do this. If you’re going to be putting your pages on an inter-
nal or external server belonging to your employer or your school, you won’t need
your own hosting. But if you’re creating a new website that will be available on the
Internet, you need some sort of hosting arrangement.
3. Associate your domain name with your new website, if you have registered one.
Your domain registrar and hosting company should provide instructions for setting
it up so that your domain name points to your hosting account. That way when
users enter your domain name in a URL, they’ll get the content that you upload to
your server.
4. Start uploading your content. When your web hosting is set up, you can use what-
ever tool you prefer to start uploading web content to the server. Many hosts pro-
vide a web interface that can allow you to upload content, but usually it’s much
easier to use a file transfer tool that supports File Transfer Protocol (FTP), Secure
Copy (SCP), or Secure FTP (SFTP) to get your files to the server.
There will be a more extensive discussion of web hosting and how to publish your site in
Lesson 20, “Putting Your Site Online,” but I wanted to give you a head start if you’re
eager to start publishing on the Web.
Summary
Designing a website, like designing a book outline, a building plan, or a painting, can
sometimes be a complex and involved process. Having a plan before you begin can help
you keep the details straight and help you develop the finished product with fewer false
starts. In this lesson, you learned how to put together a simple plan and structure for cre-
ating a set of web pages, including the following:
n

ficult. And the result might not be what you expected, making it hard for people to
get the information they need out of your website and making it difficult for you to
reorganize it so that it makes sense. Having a plan before you start can’t hurt, and
it might save you time in the long run.
Q You talked a lot in this lesson about organizing topics and pages, but you said
nothing about the design and layout of individual pages. Why?
A I discuss design and layout later in this book, after you’ve learned more about the
sorts of layout that HTML (the language used for web pages) can do and the stuff
that it just can’t do. You’ll find a whole day and more about page layout and
design in Lesson 18, “Writing Good Web Pages: Do’s and Don’ts.”
Q What if I don’t like any of the basic structures you talked about in this lesson?
A Then design your own. As long as your visitors can find what they want or do what
you want them to do, no rules say you must use a hierarchy or a linear structure. I
presented these structures only as potential ideas for organizing your web pages.
Workshop
47
2
Download from www.wowebook.com
ptg
Quiz
1. How would you briefly define the meaning of the terms website, web server, and
web pages?
2. In terms of web publishing, what’s the meaning of the term home page?
3. After you set a goal or purpose for your website, what’s the next step to designing
your pages?
4. Regardless of the navigation structure you use in your website, there’s one link that
should typically appear on each of your web pages. What is it?
5. What’s the purpose of a storyboard?
Quiz Answers
1. A website is one or more web pages linked together in a meaningful way. A web

lesson, you get to create your first (albeit brief) web page, learn about
HTML (the language for writing web pages), and learn about the following:
n
What HTML is and why you have to use it
n
What you can and cannot do when you design HTML pages
n
What HTML tags are and how to use them
n
How to write pages that conform to the XHTML standard
n
How you can use Cascading Style Sheets to control the look and
feel of your pages
Download from www.wowebook.com
ptg
What HTML Is (And What It Isn’t)
Take note of just one more thing before you start actually writing web pages. You should
know what HTML is, what it can do, and most important, what it can’t do.
HTML stands for Hypertext Markup Language. HTML was based on the Standard
Generalized Markup Language (SGML), a much larger, more complicated document-
processing system. To write HTML pages, you won’t need to know much about SGML.
However, knowing that one of the main features of SGML is that it describes the general
structure of the content inside documents—rather than its actual appearance on the page
or onscreen—does help. This concept might be a bit foreign to you if you’re used to
working with WYSIWYG (What You See Is What You Get) editors such as Adobe’s
Dreamweaver or Microsoft FrontPage, so let’s go over the information carefully.
HTML Describes the Structure of a Page
HTML, by virtue of its SGML heritage, is a language for describing the structure of a
document, not its actual presentation. The idea here is that most documents have com-
mon elements—for example, titles, paragraphs, and lists. Before you start writing, there-

So, as with the magazine example and the layout person who formats your article, the
layout person’s job is to decide how big the heading should be and what font it should be
in. The only thing you have to worry about is marking which section is supposed to be a
heading.
What HTML Is (And What It Isn’t)
51
3
Although HTML doesn’t say much about how a page looks when
it’s viewed, Cascading Style Sheets (CSS) enable you to apply
advanced formatting to HTML tags. HTML has evolved to the point
where web publishers are intended to use CSS for formatting
instructions. I’ll talk about CSS later in this lesson.
Web browsers, in addition to providing the networking functions to retrieve pages from
the Web, double as HTML formatters. When you read an HTML page into a browser
such as Firefox, Safari, or Internet Explorer, the browser interprets, or parses, the HTML
tags and formats the text and images on the screen. The browser has mappings between
the names of page elements and actual styles on the screen; for example, headings might
be in a larger font than the text on the rest of the page. The browser also wraps all the
text so that it fits into the current width of the window.
Different browsers running on diverse platforms might style elements differently. Some
browsers might use different font styles than others. For example, a browser on a desktop
computer might display italics as italics, whereas a handheld device or mobile phone
might use reverse text or underlining on systems that don’t have italic fonts. Or it might
put a heading in all capital letters instead of a larger font.
NOTE
Download from www.wowebook.com
ptg
What this means to you as a web page designer is that the pages you create with HTML
might look different from system to system and from browser to browser. The actual
information and links inside those pages are still there, but the onscreen appearance

Download from www.wowebook.com
ptg
Throughout this book, I’ll show you examples of HTML code and what they look like
when displayed.
How Markup Works
HTML is a markup language. Writing in a markup language means that you start with
the text of your page and add special tags around words and paragraphs. The tags indi-
cate the different parts of the page and produce different effects in the browser. You learn
more about tags and how they’re used in the next section.
HTML has a defined set of tags you can use. You can’t make up your own tags to create
new styles or features. And just to make sure that things are confusing, various browsers
support different sets of tags. To further understand this, take a brief look at the history
of HTML.
A Brief History of HTML Tags
HTML 2.0 was the original standard for HTML (a written specification for it is devel-
oped and maintained by the W3C) and the set of tags that all browsers must support.
Most of the tags in that original specification are still supported. In the next few lessons,
you primarily learn to use tags that were first introduced in HTML 2.0.
The HTML 3.2 specification was developed in early 1996. Several software vendors,
including IBM, Microsoft, Netscape Communications Corporation, Novell, SoftQuad,
Spyglass, and Sun Microsystems, joined with the W3C to develop this specification.
Some of the primary additions to HTML 3.2 included features such as tables, applets,
and text flow around images.
What HTML Is (And What It Isn’t)
53
3
Do design your pages so that they
work in most browsers.
Do focus on clear, well-structured
content that’s easy to read and

lar, and other browsers such as Apple Safari, Google Chrome, and Opera are in the mix,
too. Although they release new versions frequently, all of them are focused on imple-
menting web standards instead of introducing nonstandard features of their own. The
most important recent development, however, has been the expansion of the Web onto
mobile devices. Mobile phones and other devices are growing more powerful and popu-
lar, and it is becoming more important for web developers to consider these platforms
when designing their browsers.
The extra work involved in dealing with variations between browsers and platforms has
been a headache for web developers for a long time. Keeping track of all this information
can be confusing. Throughout this book, as I introduce each tag, I explain any browser-
specific issues you may encounter.
The Current Standard: XHTML 1.1
XHTML 1.1 is written in Extensible Markup Language (XML), and is the current
standard that most web developers adhere to. The X stands for XML, which is another
markup standard derived from SGML. The main difference from HTML is that XML
has strict rules for document structure. Whereas HTML 4 was forgiving of unclosed
NOTE
Download from www.wowebook.com
ptg
elements, for an XML document to be valid, every tag must be closed, every attribute
must have a value, and more. XHTML 1.1 requires that HTML documents also be valid
XML.
Technically, XHTML 1.1 and HTML 4.01 are very similar. The tags and attributes are
almost the same, but a few simple rules have to be followed to make sure that a docu-
ment complies with the XHTML 1.1 specification. Throughout this book, I explain how
to deal with the different HTML tags to ensure that your pages are readable and still look
good in all kinds of browsers.
The Future Standard: HTML5
The W3C HTML Working Group is busy creating a new standard for HTML: HTML5.
The goal of HTML5 is to introduce new elements that more accurately reflect the state of


Nhờ tải bản gốc

Tài liệu, ebook tham khảo khác

Music ♫

Copyright: Tài liệu đại học © DMCA.com Protection Status