1. Trang chủ
  2. » Công Nghệ Thông Tin

Tài liệu Internet Development doc

53 313 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 53
Dung lượng 770,34 KB

Nội dung

Chapter 8 Internet Development i-NET+ EXAM OBJECTIVES COVERED IN THIS CHAPTER:  Define programming-related terms as they relate to Internet applications development. Content could include the following:  API  CGI  SQL  SAPI  DLL—dynamic linking and static linking  Client- and server-side scripting  Describe the differences between popular client-side and server-side programming languages. Examples could include the following:  Java  JavaScript  Perl  C  C++  Visual Basic  VBScript  JScript  XML  VRML  ASP  Content could include the following:  When to use the languages  When they are executed  Describe the differences between a relational database and a non-relational database. Copyright © 2000 SYBEX Inc., Alameda, CA. www.sybex.com  Identify when to integrate a database with a Web site and the technologies used to connect the two.  Demonstrate the ability to create HTML pages. Content could include the following:  HTML document structure  Coding simple tables, headings, forms  Compatibility between different browsers  Difference between text editors and GUI editors  Importance of creating cross-browser coding in your HTML  Identify popular multimedia extensions or plug-ins. Examples could include the following:  QTVR (QuickTime VR)  Flash  Shockwave  RealPlayer  Windows Media Player  Describe the uses and benefits of various multimedia file formats. Examples could include the following:  GIF  GIF89a  JPEG  PNG  PDF  RTF  TIFF  PostScript  EPS  BMP  MOV  MPEG  AVI  BinHex  Streaming media  Non-streaming media Copyright © 2000 SYBEX Inc., Alameda, CA. www.sybex.com T he state of the art in Internet software development is a slip- pery thing. New technologies are always emerging; others fade away as they’re recognized as too weak, too complicated, or too expensive. Your job as an Internet professional is to stay familiar, in a broad way, with what’s new in software development. Then, when you’re called upon to solve a par- ticular problem, you should be able to consult books and Internet resources to figure out which technologies apply and how to use them. There are no authorities, only people willing to teach themselves quickly. This chapter endeavors to introduce you to some Internet software and media development concepts that seem built to last, at least for a while. Understanding these will help you grasp the new developments as they appear. Network Software Concepts S un Microsystems notes in its advertisements that “the network is the computer.” Increasingly, computation has more to do with sharing informa- tion among machines than with processing it on any given machine. Clients request data from servers; servers make requests of other servers; processing jobs are shared among many machines and therefore accomplished faster. This section has to do with the design of software systems that are meant to operate in networked environments. Copyright © 2000 SYBEX Inc., Alameda, CA. www.sybex.com 340 Chapter 8  Internet Development Client-Server Architecture Client-server architecture describes a particular kind of relationship between two computers. It’s easy to assume that a server is a big, powerful computer and that a client is an everyday personal computer, but that’s not necessarily true. The server in a client-server relationship is simply a computer on which a particular resource—particular data—resides. The client is a computer that requests a copy of that information for its own use. Clients and servers don’t have to be thought of as items of hardware. They can be separate pieces of software, and indeed the two pieces of software in the equation can be running under the same processor. You can install a Web server—Apache, Personal Web Server, whatever—on your machine and request Web pages from it, using a Web browser that’s running as a separate process. For this reason, you’ll hear Web browsers referred to as “Web cli- ents,” just as programs like Apache are called “Web servers,” independent of the hardware they run on. When you surf the Web, you’re acting as the client in a series of client- server relationships. The computers that are identified by domain names— yahoo.com, amazon.com, and so on—contain collections of data. When you request a document that’s identified by a particular URL, a copy of that doc- ument is sent from the computer on which it resides (the server) to your com- puter (the client). Similarly, when you use your computer to send a query to a database server and receive a particular set of data in response, your machine is the client in a client-server relationship. Client-server transactions need not involve Web pages by any means. However, Web servers and Web clients illustrate many client-server concepts clearly, so we’ll focus on them for the present. Client Software In the case of Web surfing, a Web browser is the client software in a client- server relationship. People use their Web browsers to request information from other computers. The browsers then receive the requested information and are responsible for presenting it to their users properly. The process of interpreting and presenting information is not trivial because Web pages can consist of several different kinds of data:  Text with embedded markup information  Special, embedded content that browsers can interpret without out- side help Copyright © 2000 SYBEX Inc., Alameda, CA. www.sybex.com Network Software Concepts 341  Code written in a scripting language, which must be interpreted and executed  Code written in Java or an ActiveX language  Content that must be interpreted by a plug-in Let’s explore these different kinds of content in greater detail. Text and Markup Languages The simplest Web pages are just text documents—sequences of characters, formatted as American Standard Code for Information Interchange (ASCII)—with special sequences of characters inserted here and there to indi- cate what the text means and how it should be displayed. You’re probably somewhat familiar with the most popular Web markup language—it’s called Hypertext Markup Language (HTML)—and we’ll cover some of its details later in this chapter. For now, just know that every Web browser incorporates an HTML interpreter that interprets the HTML tags in documents. There are other markup languages; eXtensible Markup Language (XML) isn’t as concerned with how text is displayed as with the meaning of individ- ual passages of text. XML is one way to share database information among machines. Native Embedded Content In addition to their ability to interpret and display HTML-formatted text, Web browsers can display certain other kinds of data that is referred to in HTML documents. Graphics fall into this category. All Web browsers can interpret JPEG and GIF graphics; various browsers can interpret other image formats as well (Microsoft Internet Explorer, for example, can display BMP images). The pieces of software that interpret these embedded files—the interpreters— are inseparable parts of the Web browsers. Scripting Languages Sometimes, the markup tags that define Web documents include passages of code in scripting languages like JavaScript or VBScript. You can use scripting languages to provide your Web pages with a certain level of interactivity and animation. The code that makes up programs—you’ll learn more about it later in this chapter—is never compiled. It always remains readable to human beings. Web browsers that are capable of running scripting-language programs interpret the code directly, without it first being compiled. Copyright © 2000 SYBEX Inc., Alameda, CA. www.sybex.com 342 Chapter 8  Internet Development Java and ActiveX Content Though they’re kind of like graphics in the sense that they’re assigned a rect- angular region and interpreted separately from the HTML document in which they’re embedded, Java applets and ActiveX controls deserve special mention. Java applets and ActiveX Controls are little pieces of software that occupy portions of the browser windows in which they run. Plug-In Content Although browsers can make sense of and display certain kinds of content natively, other kinds of files—such as those containing certain kinds of sounds, three-dimensional graphics, and other special media—fall outside the browser’s built-in capabilities. The most popular browsers, however, can take plug-ins, which are software modules that users add to their browsers to expand their capabilities. When a browser encounters a piece of embed- ded media that it can’t interpret natively, it checks its roster of plug-ins to see if one of them can handle the content. If so, the handling is seamless—it looks to the user as if the browser can handle the content by itself. The problem with plug-ins is that no one has all of them, and you’re asking a lot of a user if you ask her to download and install a particular plug-in just to view your content. The basic rule is to stick to media that browsers can inter- pret natively. If you need to use plug-in content to get an effect you need— chemists, for example, use special file formats to display images of complex molecules in three dimensions—make sure the benefits to users are great enough to warrant the trouble of downloading and installing the plug-in. Server Software In the client-server equation as it applies to Web publishing, the Web server is both a piece of software (the program that doles out pages in response to client requests) and a unit of hardware (the physical machine on which the server software runs). Popular Web server software includes:  Apache  Microsoft Internet Information Server (IIS)  Netscape Enterprise Server Copyright © 2000 SYBEX Inc., Alameda, CA. www.sybex.com Network Software Concepts 343 Each handles requests for Web pages. They may also have capacities to work with server-side scripting languages, extensions, Java servlets, and inde- pendent server-side programs that provide some sort of processing service. Server Extensions A server extension is sort of like a plug-in for Web server software. A soft- ware module that expands the capabilities of the server software itself, server extension may be published by the same company that put out the server software or by another publisher. The Microsoft FrontPage Extensions are perhaps the most popular server extensions around. They allow servers to support some of the interactive features Microsoft FrontPage lets developers embed in their pages. Java Servlets Java servlets are special Java programs that expand the capabilities of Web server software. Similar to server extensions, the advantage of a Java servlet is that a single, properly designed servlet will run under any operating sys- tem for which there is a Java Virtual Machine (JVM)—the same as any Java program. Server-Side Scripting Languages Server-side scripting languages are programming languages designed for writing code that’s embedded in Web pages and interpreted before those pages are sent out to the client. Active Server Pages (ASP) and Hypertext Pre- processor (PHP), both covered later in this chapter, are two of the most pop- ular server-side scripting languages. Compiled Server-Side Programs and Other Servers In addition to exercising their native capabilities and those provided by add- in servlets and extensions, Web servers may also cooperate with other kinds of server software, such as a database server. When a program written in a server-side scripting language requests data from a database server, the Web server is capable of allowing the script to access the database server and retrieve the information it needs. Copyright © 2000 SYBEX Inc., Alameda, CA. www.sybex.com 344 Chapter 8  Internet Development Communication between Client and Server If you’re going to have software that takes advantage of client-server archi- tecture, you must have mechanisms in place for transmitting information back and forth between the two elements in the equation. Forms As far as the Web is concerned, client-server communications rely upon forms in Web pages that collect information from the user. The data the user puts into those forms is then submitted (or posted) to the program on the server side. The form data is packaged and sent to the server in a format defined by the Common Gateway Interface (CGI) specification. Common Gateway Interface (CGI) The Common Gateway Interface (CGI) specification defines a way of pack- aging text data (such as the contents of a form) for transmission over a net- work. The CGI specification takes the contents of a form and the names of the form elements (as specified in HTML) and assembles them all into a long string of characters. That string can then be passed to a program on the server side for processing and a response. A CGI submission might tell a server-side database interface to search for something and return a results page, for example. Computers running Microsoft’s Internet Information Server (IIS) support the Internet Services Application Programming Inter- face (ISAPI), which can be used to carry out CGI-like tasks on IIS-equipped servers. Do not make the mistake of thinking CGI is a programming language. It is not. Although it is correct to speak of a “CGI program,” such programs are referred to that way because they accept CGI data as input (as from a Web form), not because they are written in a language called CGI. There is no such language (at least, there is none of any significance). Security The problem with CGI is that it involves the transmission of a text string— that is by default readable to anybody who cares to intercept it—across a network. If you’re using CGI to move data over the Internet, you’re exposing yourself and your client-side users to security risks. You shouldn’t ever enter Copyright © 2000 SYBEX Inc., Alameda, CA. www.sybex.com Network Software Concepts 345 sensitive information such as credit card data into a form for CGI transmis- sion unless you’re sure the transmission will be protected. How are CGI submissions protected? Typically, Secure Sockets Layer (SSL) encrypts data transmitted between a client and a server. Read all about SSL and other encryption technologies in Chapter 7. Trends in Network Computing For many years, the trend in computing technology was toward more stor- age space, faster processors, more capable software, and lower prices on everything. Now it seems that, although “more, faster, and cheaper” will always be appealing, computer technology is getting to be “good enough” for many everyday applications. Personal computers spend most of their processor cycles idling, waiting for their human users to do something. The trends in computer technology have mainly to do with network computing, which is computing performed by multiple computers linked together on some kind of network. Whether the collaborative computing has to do with sharing information or sharing processor power, it seems that a network often provides more computing power than its component machines could if they were acting alone. You can distinguish the two main trends in networking by determining what is shared:  In enterprise computing, it’s typically the data that’s shared. One machine can access and operate upon information from another or from a central repository.  In distributed computing, the processing work is spread over several machines. Of course, there’s some overlap, and it’s not always easy to tell where pro- cessing begins and data-sharing ends. Let’s explore these trends further. Enterprise Computing Enterprise computing has to do with sharing information among the appli- cations with which an organization, such as a company or a unit of gov- ernment, does its business. This kind of sharing can help the company realize efficiencies in its overall process of buying, making, processing, and selling goods and services and in the accounting, finance, human resources, and management infrastructures it maintains to facilitate those processes. An Enterprise Resource Planning (ERP) system, because of its purchasing Copyright © 2000 SYBEX Inc., Alameda, CA. www.sybex.com 346 Chapter 8  Internet Development features, might note that two different plants were buying the same part from different suppliers. Because of its integration with the manufacturing process, it might note that one supplier’s products had far fewer defects than the other’s did. The two purchasing agents at the plants might have had spotty communication without the ERP system, but the ERP system is much better able to spot situations like this and advise the buyer of the faulty parts to try the other plant’s supplier. SAP (pronounced as three distinct letters), a German company, is gener- ally recognized as the world leader in enterprise computing. Its flagship ERP product, SAP R/3, is standard equipment among very large organizations all over the world, and SAP consultants make very good coin planning, imple- menting, and expanding SAP R/3 installations. The trend is beginning to trickle down to smaller companies, as well, and some pundits expect that technologies like XML will make it easier to share information among small- business software products from many publishers. SAP has several Web sites, each of which highlights some aspect of its busi- ness. The main one, www.sap.com, will direct you to the information you need. Another site, www.mysap.com, focuses on SAP’s products and services for companies somewhat smaller than enormous. Distributed Computing Distributed computing has to do with spreading portions of a computing job over several machines. This is not parallel processing, in which an operating system divides the running of some program over several CPUs, but rather a system of sharing discrete business tasks over several machines. The dis- crete tasks might include the following:  Collecting data  Managing a database that stores the data  Analyzing the data  Performing financial operations (such as billing) based on the data Any given task might require work from several machines, each of which is responsible for one of the above. The load is spread, and therefore the job is completed more quickly. Copyright © 2000 SYBEX Inc., Alameda, CA. www.sybex.com [...]... focus on highly capable, fullfeatured development languages and slightly less capable (but simpler) scripting languages Copyright © 2000 SYBEX Inc., Alameda, CA www.sybex.com 348 Chapter 8 Internet Development Full-Featured Development Languages A full-featured development language is one that can be used to write standalone programs You can use a full-featured development language to write an elaborate... format—all of it … defines the head segment of the document, in which some scripting code and other invisible elements will go … defines the body segment of the document, in which visible elements will go You also can add some simple elements to provide your document with some content Here’s another document: ... the table’s exterior: Copyright © 2000 SYBEX Inc., Alameda, CA www.sybex.com 368 Chapter 8 Internet Development Here’s an HTML document that illustrates the use of table-making tags: A Very Simple HTML Document Rainfall Values Inches Very good!... process and respond to the CGI string FIGURE 8.6 An HTML document that includes a form Compatibility with Different Browsers When writing HTML, you have to be concerned with how your pages will look when interpreted by each of the many browsers that Internet surfers Copyright © 2000 SYBEX Inc., Alameda, CA www.sybex.com 372 Chapter 8 Internet Development use At the very least, you should verify that . Chapter 8 Internet Development i-NET+ EXAM OBJECTIVES COVERED IN THIS CHAPTER:  Define programming-related terms as they relate to Internet applications development. . Alameda, CA. www.sybex.com 348 Chapter 8  Internet Development Full-Featured Development Languages A full-featured development language is one that can be

Ngày đăng: 21/12/2013, 04:19

TỪ KHÓA LIÊN QUAN

w