Introduction to Web Interface Technology (CSE2030)
Published byModified over 5 years ago
Presentation on theme: "Introduction to Web Interface Technology (CSE2030)"— Presentation transcript:
1 Introduction to Web Interface Technology (CSE2030)
2 Objectives Learn about the architecture of the World Wide Web Learn about addressingLearn about the difference between static and dynamic Web pagesExamine different technologies that can be used to create dynamic Web pages that interact with a database
3 Web BasicsThe Web consists of computers on the Internet connected to each other in a specific wayThe Web has a client/server architectureWeb browsersAlso called browsersPrograms used to connect client-side computers to the Internet
4 Web Basics Web servers Run special Web server software Listener Component included in Web server softwareMonitors for messages sent to it from client browsers
5 Web BasicsWeb pageUsually a file with an .htm or .html extension that contains Hypertext Markup Language (HTML) tags and textHTMLDocument layout language (not a programming language)Defines structure and appearance of Web pagesAllows Web pages to embed hypertext links to other Web pages
6 Figure 1-1: Web client/server architecture Web BasicsFigure 1-1: Web client/server architecture
7 Communication Protocols and Web Addresses Agreements between sender and receiver regarding how data are sent and interpretedInternet is built on two network protocols:Transmission Control Protocol (TCP)Internet Protocol (IP)Interaction b/w Browser and Server is governed by the HTTP protocol (Request/Response Tx)HTTP is stateless!(Will discuss in more detail when processing forms)
8 Communication Protocols and Web Addresses PacketsData that can be routed independently through InternetDomain nameRepresents an IP addressA domain names server maintains tables with domain names matched to their IP addressesInternet Service Providers (ISPs)Provide commercial Internet access
9 Communication Protocols and Web Addresses Hypertext Transfer ProtocolCommunication protocol used on the WebWeb addressAlso called Uniform Resource Locator (URL)Figure 1-2: URL Components
10 Communication Protocols and Web Addresses If folder path is not specified, Web server assumes default starting point is Web server’s root document folderFigure 1-3: URL that displays default home page
11 Communication Protocols and Web Addresses Internet URLsSpecify a Web server or domain nameSpecify communication protocol as first part of URLFile URLHTML file stored on user’s hard drive
12 Running Multiple Listener Processes on the Same Web Server Running multiple listeners is managed through the concept of portsPortsIdentified by a number that specifies which TCP/IP-based listener or server running on a computer, at a given IP address, is going to receive a message coming in from the networkYou will set up a port for the Apache server on SNG
13 Other Web Terms - CSS CSS – Cascading style sheet Used to define HTML formatting styles for multiple pagesNeeds to be “included” in each page that is to use the formatting.Example:
14 Other Web Terms - XMLXML was designed to describe data, and to focus on what data is.HTML was designed to display data, and to focus on how data looks.XML does not DO anythingXML was not designed to DO anything.The following example is a note to Tove from Jani, stored as XML:<note><to>Tove</to><from>Jani</from><heading>Reminder</heading><body>Don't forget me this weekend!</body></note>XML tags are not predefined. You must "invent" your own tags.
15 XML cont 1. With XML, plain text files can be used to share data. Since XML data is stored in plain text format, XML provides a software- and hardware-independent way of sharing data.With XML, your data is available to more users.Since XML is independent of hardware, software and application, you can make your data available to other than only standard HTML browsers.
16 XML cont 2. XML documents use a self-describing and simple syntax. <?xml version="1.0" encoding="ISO "?><note date="12/11/99"><to>Tove</to><from>Jani</from></note>See:
17 Personal and Client/Server Databases Using a client/server database for a multiuser application
18 Personal and Client/Server Databases A client/server database is less affected when a client workstation failsThe failed client’s in-progress queries are lost, but the failure of a single client workstation does not affect other usersIn case of server failure in a client/server database, a central synchronized transaction log contains a record of all current database changes
19 Personal and Client/Server Databases Personal databases are useful:For Web installations where the only database operation is viewing data and no action queries are usedWhere less robust recovery and security systems can be toleratedEg MS Access.
20 Personal and Client/Server Databases Longstanding and useful guidelineWhen a personal database is used for multiuser applications, usage should be limited to no more than 10 concurrent users if action queries are allowedIf security or the ability to recover from client or server failures is important, use a client/server DBMS regardless of the number of concurrent usersYou will use Oracle and SQL Server.
21 Dynamic Web Pages Static Web page Dynamic Web page Page content established at the time page is createdUseful for displaying data that doesn’t change often, and for navigating between HTML Web page filesDynamic Web pageAlso called an interactive Web pagePage content varies according to user requests or inputs
22 Figure 1-7: Database-driven Web site Architecture Dynamic Web PagesFigure 1-7: Database-driven Web site Architecture
23 Dynamic Web PagesFigure 1-8: Database-driven Web site architecture for action query
24 Approaches for Creating Dynamic Web Pages In server-side processing, the Web server:Receives the dynamic Web page requestPerforms all of the processing necessary to create the dynamic Web pageSends the finished Web page to the client for display in the client’s browser
26 Approaches for Creating Dynamic Web Pages CurlASP.NETJSP, PHPFigure 1-9: Server-side and client-side Web database technologies
27 Client-side Processing One approach to client-side processing involves downloading compiled executable programs stored on the Web server to the user’s Web browser and then running them on the user’s workstationThis program interfaces with the user and, as needed, sends and retrieves data from a database serverA Java applet uses this approach
29 Client-side Processing Microsoft’s ActiveX also sends a compiled executable program to the user’s workstationActiveX program are generally used to create intranet applicationsAn intranet is a self-contained internal corporate network based on Internet protocols but separate from the InternetActive X programs are capable of modifying data on the client machine (eg registry) – security risk
31 Server-side Processing The most common server-side dynamic Web page technology uses HTML formsEnhanced documents designed to collect user inputs and send them to the Web serverHTML forms allow users to input data using text boxes, option buttons, and listsWhen the form is submitted, the servicing program on the Web server process the form inputs and dynamically composes a Web page reply
32 Server-side Processing Common Gateway Interface (CGI) protocolUsed as a method for communicating between the HTML form and the servicing programDisadvantage of using CGI-based servicing programs is that each form submitted to a Web server starts its own copy of the servicing program, potentially causing memory problems for the Web serverStarts another program/script to perform processing.Often written in PHP, PERL, Shell scripts, C.
33 Server-side Processing Web server vendors have developed proprietary technologies to process form inputs without starting a new copy of the servicing program for every formNetscape’s Netscape Service Application Programming Interface (NSAPI)Microsoft’s Internet Server Application Programming Interface (ISAPI)
34 Server-side Processing Another approach for creating dynamic Web pages using server-side processing uses server-side scriptsServer-side script is uncompiled code included within an HTML Web page file to extend its capabilitiesExamples of technologies using this approach include Server-side includes (SSIs) and Microsoft Active Server Pages (ASPs)From 2002, Microsoft’s ASP.NET
35 Server-side Processing JSP – Java server pages – combine markup (HTML or XML) with Java code to dynamically create web pages.ColdFusion – proprietary product which uses <CF…/CF> tags to invoke functions on the serverASP.NET ‘similar’ to ASP but can use any language to write code; is OO; separates code from HTML form.We will use VB.NET (full programming language not just a script).