Presentation is loading. Please wait.

Presentation is loading. Please wait.

Introduction to Web Database By Rimpi Suman 1 1 Unit-6.

Similar presentations


Presentation on theme: "Introduction to Web Database By Rimpi Suman 1 1 Unit-6."— Presentation transcript:

1 Introduction to Web Database By Rimpi Suman 1 1 Unit-6

2 Contents By Rimpi Suman 2  World Wide Web  Client Side scripting & Applets  Web Server & Session  Web Services  Server side Scripting  XML  Structure of XML Data  XML document Schema  Xquery  Storage of XML Data  XML Application 2

3 By Rimpi Suman 3 World Wide Web

4 By Rimpi Suman 4

5 Web client/server architecture By Rimpi Suman 5

6 Communication Protocols and Web Addresses By Rimpi Suman 6 Web address –Also called Uniform Resource Locator (URL) URL Components

7 Basics of Web: Client and Server By Rimpi Suman 7 Server : A program that provides services to other programs. It stands ready for requests and when it gets a request, it provides the service. Client : A program requesting a service of a server program. It makes a request, gets the service, and makes use of it.

8 Basics of Web: HTML and HTTP By Rimpi Suman 8 HyperText Markup Language - Allows “marking up” a document with tags specifying appearance and structure. HyperText Transfer Protocol - Protocol used for browsers to communicate with web servers. Basically, this consists of“requests” from the browser and “responses” from the server.

9 Basics of Web:Web Browsers and Servers By Rimpi Suman 9 Web server - This is a program that runs on the internet host computer (server machine). It takes requests for web pages from clients and delivers the pages back to the client. Web browser - This is a program that runs on your local PC (client). It allows you to request web pages from an internet host.

10 Task’s Of Web Server: By Rimpi Suman 10 Handling a client request consists of several key steps:  Parsing the request message  Checking that the request is authorized  Associating the URL in the request with a file name  Constructing the response message  Transmitting the response message to the requesting client

11 “Web Site! Vs Web Server!” By Rimpi Suman 11  Web site and Web server are different:  A Web site consists of a collection of Web pages associated with a particular hostname.  A Web server is a program to satisfy client requests for Web resources.

12 Typical HTML Request  Client Side (Browser)  Issues request for HTML page  Receives response HTML page  Interprets HTML and creates web page  Displays web page  Work is done here  Server Side  Reads request from client  Finds page on server  Sends response page to client  Essentially a file server By Rimpi Suman 12

13 HyperText Markup Language By Rimpi Suman 13 Sample HTML Source Code ID Name Department 36814021 J.Muzamil Idroos Comp. Sci. ID Name Department 36814022 N.Parthiban Comp. Sci. ID Name Department 36814024 R.siva Comp. Sci. ID Name Department 36814023 S.Ramachandran Comp. Sci. Student Instructor Name:

14 By Rimpi Suman 14

15 Output of HTML source code By Rimpi Suman 15

16 By Rimpi Suman 16 HTML codes are written using Text editor,there are number of editors that permit direct creation of HTML by using graphical interface Eg: Adobe DreamWeaver HTML supports stylesheets, which can alter the default definition of how an HTML formatting contruct is displayed. Cascading Style Sheets (CSS)used for multiple HTML documents,giving distinct but uniform look to page on a web site…

17 Cascading Style Sheets By Rimpi Suman 17 #nav { width: 100%; float: right; background-color: #F2F5A9; } #nav li { text-align: left; float:left; } #nav li a { display: block; padding: 15px 45px; text-decoration: BOLD; font-weight: bold; color: #088A29; } #nav li a:hover { color: #FF0000; border-right: 5px solid #FFFFFF; } For top menu widget

18 HTML page without CSS By Rimpi Suman 18

19 HTML pagewith CSS By Rimpi Suman 19

20 Dynamic and Static Web pages By Rimpi Suman 20 Static Web page –Page content established at the time page is created –Useful for displaying data that doesn’t change often, and for navigating between HTML Web page files Dynamic Web page –Also called an interactive Web page –Page content varies according to user requests or inputs

21 Approaches for Creating Dynamic Web Pages By Rimpi Suman 21 In server-side processing, the Web server: –Receives the dynamic Web page request –Performs all of the processing necessary to create the dynamic Web page –Sends the finished Web page to the client for display in the client’s browser

22 Approaches for Creating Dynamic Web Pages(cont..) By Rimpi Suman 22 Client-side processing –Some processing is done on the client workstation, either to form the request for the dynamic Web page or to create or display the dynamic Web page –Eg: JavaScript code to validate user input. –Often needs to be “executed” by the Browser.

23 Server-side and client-side Web database technologies By Rimpi Suman 23

24 Client Side Scripting and Applets By Rimpi Suman 24 Scripting languages - Allow us to add capability to what’s provided by HTML. Allow parts of the page to be built “on the fly”. These scripts are “interpreted” as they run rather than being compiled. Client-side scripts - Script engine on client machine builds parts of page when page is loaded by browser (date is simple example). JavaScript is prime example.

25 Client Side Scripting and Applets(cont..) By Rimpi Suman 25 JavaScript is commonly used in variety of tasks Exaple:Validation,such as date format,value entered in appropriate range(such as range).

26 Client Side Scripting and Applets(cont..) Applets are java programs that can be embedded in HTML documents and can run inside a web browser. The applet code resides on the web server and gets downloaded in the browser whenever the web page containing the applet is requested by the browser. MySQL is the world's most popular open source database. By Rimpi Suman 26

27 Server-side Processing Web Servers and Sessions: By Rimpi Suman 27 1. The most common server-side dynamic Web page technology uses HTML forms –Enhanced documents designed to collect user inputs and send them to the Web server –HTML forms allow users to input data using text boxes, option buttons, and lists 2. web session, the session is a data structure that an application uses to store temporary data that is useful only during the time a user is interacting with the application, it is also specific to the user.

28 Cookies By Rimpi Suman 28 A cookie is a small piece of text containing identifying information –Sent by server to browser Sent on first interaction, to identify session –Sent by browser to the server that created the cookie on further interactions part of the HTTP protocol –Server saves information about cookies it issued, and can use it when serving a request E.g., authentication information, and user preferences Cookies can be stored permanently or for a limited time

29 Servlets By Rimpi Suman 29 Javaservlets are pieces of Java code that run in Web servers. There are special conventions on how to read the input from the user request and how to write output generated by the servlet. Servlets are truly platform-independent, and so they have become very popular with Web developers.

30 Server side Scripting By Rimpi Suman 30 Several scripting language are available in recent years eg: JavaScript,Jscript,Java Server Page(JSP),HyperText Preprocessor(PHP),Active Server Pages(ASP)..etc. It is even possible to embed code written in VBScript,Perl,and Python into HTML pages.ASP supports embedded VBScripts and Jscripts.

31 Server side Scripting(cont..) By Rimpi Suman 31 PHP is widely used for Web server scripting Extensive libaries including for database access using ODBC Hello <?php if (!isset($_REQUEST[‘name’])) { echo “Hello World”; } else { echo “Hello, ” + $_REQUEST[‘name’]; } ?>

32 Web Service By Rimpi Suman 32

33 Types Of web service Big Web Service (SOAP) RESTful web sevice By Rimpi Suman 33

34 Big Web Service Big web services are based on SOAP standard that use XML message. An XML language define Message format and message standard. By Rimpi Suman 34

35 SOAP(Simple object access protocol) SOAP provide an envelop for transferring message over internet. By Rimpi Suman 35

36 RESTful web service RESTful web services are based on the way how our web works. Our very own world wide web (www) – the largest distributed application – is based on an architectural style called REST – Representational State Transfer. REST is neither a standard nor a protocol. It is just an architectural for example client-server architecture (client-server is neither a standard nor a protocol). Web services following this architectural style are said to be RESTful Web services. By Rimpi Suman 36

37 37 Web-DBMS Advantages By Rimpi Suman 37 Simplicity Platform Independence GUI Cross-Platform Support Scalable Deployment

38 38 Web-DBMS Disadvantages By Rimpi Suman 38 Reliability Security Cost – commercial web site cost high Scalability Limited Functionality of HTML Bandwidth Performance


Download ppt "Introduction to Web Database By Rimpi Suman 1 1 Unit-6."

Similar presentations


Ads by Google