×

Your First XML Document

消耗积分:3 | 格式:rar | 大小:666 | 2008-10-07

golabs

分享资料个

This chapter teaches you how to create simple XML documents
with tags you define that make sense for your
document. You’ll learn how to write a style sheet for the document
that describes how the content of those tags should
be displayed. Finally, you’ll learn how to load the documents
into a Web browser so that they can be viewed.
Since this chapter will teach you by example, and not from
first principals, it will not cross all the t’s and dot all the i’s.
Experienced readers may notice a few exceptions and special
cases that aren’t discussed here. Don’t worry about these;
you’ll get to them over the course of the next several chapters.
For the most part, you don’t need to worry about the
technical rules right up front. As with HTML, you can learn
and do a lot by copying simple examples that others have
prepared and modifying them to fit your needs.
Toward that end I encourage you to follow along by typing in
the examples I give in this chapter and loading them into the
different programs discussed. This will give you a basic feel
for XML that will make the technical details in future chapters
easier to grasp in the context of these specific examples.
Hello XML
This section follows an old programmer’s tradition of introducing
a new language with a program that prints “Hello World” on
the console. XML is a markup language, not a programming language;
but the basic principle still applies. It’s easiest to get
started if you begin with a complete, working example you can
expand on rather than trying to start with more fundamental
pieces that by themselves don’t do anything. And if you do
encounter problems with the basic tools, those problems are a lot easier to debug and fix in the context of the short, simple documents used here
rather than in the context of the more complex documents developed in the rest of
the book.
In this section, you’ll learn how to create a simple XML document and save it in a
file. We’ll then take a closer look at the code and what it means.

声明:本文内容及配图由入驻作者撰写或者入驻合作网站授权转载。文章观点仅代表作者本人,不代表电子发烧友网立场。文章及其配图仅供工程师学习之用,如有内容侵权或者其他违规问题,请联系本站处理。 举报投诉

评论(0)
发评论

下载排行榜

全部0条评论

快来发表一下你的评论吧 !