mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai...

96
TMS Tecnologie dell’informazione: mercato, società, cultura

Transcript of mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai...

Page 1: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

TMS

Tecnologie dell’informazione:

mercato, società, cultura

Page 2: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Contenuti della presentazione

• HTML

• W3C

• XML

• DTD

• Web Client

• Web Server

Page 3: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Un esempio di pagina HTML

Page 4: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...
Page 5: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...
Page 6: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...
Page 7: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...
Page 8: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...
Page 9: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...
Page 10: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Cosa c’è dietro questa pagina?

Page 11: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

<html><head><title>Semplice pagina di esempio</title>

</head><body><center><h1>Home Simpson</h1><img src="img/homer.jpg">

</center><p><b>Homer</b>: Ok, cervello, io non piaccio a

te e tu non piaci a me, ma facciamola questa cosa così potrò tornare a sbomballarti con la birra!<br><b>Cervello</b>: Affare fatto!

</p><a href="www.thesimpsons.com/">The

Simpsons Movie</a></body></html>

Page 12: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

<html><head><title>Semplice pagina di esempio</title>

</head><body><center><h1>Home Simpson</h1><img src="img/homer.jpg">

</center><p><b>Homer</b>: Ok, cervello, io non piaccio a

te e tu non piaci a me, ma facciamola questa cosa così potrò tornare a sbomballarti con la birra!<br><b>Cervello</b>: Affare fatto!

</p><a href="www.thesimpsons.com/">The

Simpsons Movie</a></body></html>

Page 13: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

<html><head><title>Semplice pagina di esempio</title>

</head><body><center><h1>Home Simpson</h1><img src="img/homer.jpg">

</center><p><b>Homer</b>: Ok, cervello, io non piaccio a

te e tu non piaci a me, ma facciamola questa cosa così potrò tornare a sbomballarti con la birra!<br><b>Cervello</b>: Affare fatto!

</p><a href="www.thesimpsons.com/">The

Simpsons Movie</a></body></html>

Page 14: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

<html><head><title>Semplice pagina di esempio</title>

</head><body><center><h1>Home Simpson</h1><img src="img/homer.jpg">

</center><p><b>Homer</b>: Ok, cervello, io non piaccio a

te e tu non piaci a me, ma facciamola questa cosa così potrò tornare a sbomballarti con la birra!<br><b>Cervello</b>: Affare fatto!

</p><a href="www.thesimpsons.com/">The

Simpsons Movie</a></body></html>

Page 15: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

<html><head><title>Semplice pagina di esempio</title>

</head><body><center><h1>Home Simpson</h1><img src="img/homer.jpg">

</center><p><b>Homer</b>: Ok, cervello, io non piaccio a

te e tu non piaci a me, ma facciamola questa cosa così potrò tornare a sbomballarti con la birra!<br><b>Cervello</b>: Affare fatto!

</p><a href="www.thesimpsons.com/">The

Simpsons Movie</a></body></html>

Page 16: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

<html><head><title>Semplice pagina di esempio</title>

</head><body><center><h1>Home Simpson</h1><img src="img/homer.jpg">

</center><p><b>Homer</b>: Ok, cervello, io non piaccio a

te e tu non piaci a me, ma facciamola questa cosa così potrò tornare a sbomballarti con la birra!<br><b>Cervello</b>: Affare fatto!

</p><a href="www.thesimpsons.com/">The

Simpsons Movie</a></body></html>

Page 17: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Un Tag

<nomeTag attributi> contenuto </nomeTag>

Esempio:

<a href="www.thesimpsons.com">The Simpsons Movie</a>

Page 18: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Tag di Apertura

Un Tag

<nomeTag attributi> contenuto </nomeTag>

Esempio:

<a href="www.thesimpsons.com">The Simpsons Movie</a>

Page 19: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Tag diChiusura

Un Tag

<nomeTag attributi> contenuto </nomeTag>

Esempio:

<a href="www.thesimpsons.com">The Simpsons Movie</a>

Page 20: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Un Tag

<nomeTag attributi> contenuto </nomeTag>

Esempio:

<a href="www.thesimpsons.com">The Simpsons Movie</a>

Nome = “valore”

Page 21: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

ValoreNo

me

Un Tag

<nomeTag attributi> contenuto </nomeTag>

Esempio:

<a href="www.thesimpsons.com">The Simpsons Movie</a>

Nome = “valore”

Page 22: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Struttura di un documento HTML

Page 23: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

<html><head><title>Semplice pagina di esempio</title>

</head><body><center><h1>Home Simpson</h1><img src="img/homer.jpg">

</center><p><b>Homer</b>: Ok, cervello, io non piaccio a te e tu non piaci a me, ma facciamola questa cosa così potrò tornare a sbomballarti con la birra!<br> <b>Cervello</b>: Affare fatto!

</p><a href="www.thesimpsons.com/">The Simpsons Movie</a>

</body></html>

Page 24: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

<html><head><title>Semplice pagina di esempio</title>

</head><body><center><h1>Home Simpson</h1><img src="img/homer.jpg">

</center><p><b>Homer</b>: Ok, cervello, io non piaccio a te e tu non piaci a me, ma facciamola questa cosa così potrò tornare a sbomballarti con la birra!<br> <b>Cervello</b>: Affare fatto!

</p><a href="www.thesimpsons.com/">The Simpsons Movie</a>

</body></html>

Page 25: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

<html><head><title>Semplice pagina di esempio</title>

</head><body><center><h1>Home Simpson</h1><img src="img/homer.jpg">

</center><p><b>Homer</b>: Ok, cervello, io non piaccio a te e tu non piaci a me, ma facciamola questa cosa così potrò tornare a sbomballarti con la birra!<br> <b>Cervello</b>: Affare fatto!

</p><a href="www.thesimpsons.com/">The Simpsons Movie</a>

</body></html>

Page 26: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

<html><head><title>Semplice pagina di esempio</title>

</head><body><center><h1>Home Simpson</h1><img src="img/homer.jpg">

</center><p><b>Homer</b>: Ok, cervello, io non piaccio a te e tu non piaci a me, ma facciamola questa cosa così potrò tornare a sbomballarti con la birra!<br> <b>Cervello</b>: Affare fatto!

</p><a href="www.thesimpsons.com/">The Simpsons Movie</a>

</body></html>

Page 27: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

<html><head><title>Semplice pagina di esempio</title>

</head><body><center><h1>Home Simpson</h1><img src="img/homer.jpg">

</center><p><b>Homer</b>: Ok, cervello, io non piaccio a te e tu non piaci a me, ma facciamola questa cosa così potrò tornare a sbomballarti con la birra!<br> <b>Cervello</b>: Affare fatto!

</p><a href="www.thesimpsons.com/">The Simpsons Movie</a>

</body></html>

Page 28: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

DOCTYPE

<!DOCTYPE HTML PUBLIC

"-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

Page 29: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

DOCTYPE

<!DOCTYPE HTML PUBLIC

"-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

Page 30: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

DOCTYPE

<!DOCTYPE HTML PUBLIC

"-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

Page 31: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

DOCTYPE

<!DOCTYPE HTML PUBLIC

"-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

Page 32: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

DOCTYPE

<!DOCTYPE HTML PUBLIC

"-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">

Page 33: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

W3C

To lead the World Wide Web to its full potential by developing protocols and guidelines that ensure long-term growth for the Web.

Page 34: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

W3C

• CSS• CGI• DOM• HTML• RDF• SVG• SOAP• SMIL• SRGS• SSML

• VoiceXML• WSDL• XHTML• XML• XML Information Set• XML Schema• XPath• XQuery• XSLT

Page 35: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

W3C

• CSS• CGI• DOM• HTML• RDF• SVG• SOAP• SMIL• SRGS• SSML

• VoiceXML• WSDL• XHTML• XML• XML Information Set• XML Schema• XPath• XQuery• XSLT

Page 36: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

XML

Extensible Markup Language

Page 37: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempio: un’agenda

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

Page 38: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempio: un’agenda

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

Page 39: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempio: un’agenda

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

Page 40: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempio: un’agenda

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

Page 41: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempio: un’agenda

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

Page 42: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempio: un’agenda

<notes><note> <to>Bart</to><from>Homer</from><heading>Brutto bagarospo!</heading> <body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è:

mai tentare.</body>

</note><note> <to>Homer</to><from>Bart</from><heading>Ciucciati il calzino!</heading> <body></body>

</note></notes>

Page 43: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempio: un’agenda

<notes>

<note>

<to>

<from>

<heading>

<body>

Page 44: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempio: un’agenda

<?xml version="1.0" ?><notes><note> <to>Bart</to><from>Homer</from><heading>Brutto bagarospo!</heading> <body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è:

mai tentare.</body>

</note><note> <to>Homer</to><from>Bart</from><heading>Ciucciati il calzino!</heading> <body></body>

</note></notes>

Page 45: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempio: un’agenda

<?xml version="1.0" ?><! DOCTYPE notes SYSTEM=“notes.dtd”><notes>

<note> <to>Bart</to><from>Homer</from><heading>Brutto bagarospo!</heading> <body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai

tentare.</body>

</note><note>

<to>Homer</to><from>Bart</from><heading>Ciucciati il calzino!</heading> <body></body>

</note></notes>

Page 46: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Un esempio di DTDDocument Type Definition

<!ELEMENT notes (note* )>

<!ELEMENT note (to, from, heading , body )>

<!ELEMENT to (#PCDATA)>

<!ELEMENT from (#PCDATA)>

<!ELEMENT heading (#PCDATA)>

<!ELEMENT body (#PCDATA)>

Page 47: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT notes (note*)>

<!ELEMENT note (to, from, heading, body)>

<!ELEMENT to (#PCDATA)>

<!ELEMENT from (#PCDATA)>

<!ELEMENT heading (#PCDATA)>

<!ELEMENT body (#PCDATA)>

<?xml version="1.0" ?>

<! DOCTYPE notes SYSTEM=“notes.dtd”>

<notes>

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

</notes>

Page 48: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT notes (note*)>

<!ELEMENT note (to, from, heading, body)>

<!ELEMENT to (#PCDATA)>

<!ELEMENT from (#PCDATA)>

<!ELEMENT heading (#PCDATA)>

<!ELEMENT body (#PCDATA)>

<?xml version="1.0" ?>

<! DOCTYPE notes SYSTEM=“notes.dtd”>

<notes>

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

</notes>

Page 49: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT notes (note*)>

<notes>

</notes>

Page 50: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT notes (note*)>

<notes>

</notes>

Page 51: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT notes (note*)>

Page 52: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT notes (note*)>

Page 53: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT notes (note*)>

<!ELEMENT note (to, from, heading, body)>

<!ELEMENT to (#PCDATA)>

<!ELEMENT from (#PCDATA)>

<!ELEMENT heading (#PCDATA)>

<!ELEMENT body (#PCDATA)>

<?xml version="1.0" ?>

<! DOCTYPE notes SYSTEM=“notes.dtd”>

<notes>

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

</notes>

Page 54: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT note (to, from, heading, body)><note>

</note>

Page 55: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT note (to, from, heading, body)><note>

</note>

Page 56: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT note (to, from, heading, body)><note>

</note>

Page 57: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT notes (note*)>

<!ELEMENT note (to, from, heading, body)>

<!ELEMENT to (#PCDATA)>

<!ELEMENT from (#PCDATA)>

<!ELEMENT heading (#PCDATA)>

<!ELEMENT body (#PCDATA)>

<?xml version="1.0" ?>

<! DOCTYPE notes SYSTEM=“notes.dtd”>

<notes>

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

</notes>

Page 58: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT to (#PCDATA)><to>Bart</to>

Page 59: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT to (#PCDATA)><to>Bart</to>

Page 60: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT to (#PCDATA)><to>Bart</to>

Page 61: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

PCDATA

Parsed Character DATAI dati all’interno vengono parsati e le entità espanse.

Page 62: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

CDATA

Character DATA

I dati non vengono parsati, nessuna espansione di entità.

Page 63: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT notes (note*)>

<!ELEMENT note (to, from, heading, body)>

<!ELEMENT to (#PCDATA)>

<!ELEMENT from (#PCDATA)>

<!ELEMENT heading (#PCDATA)>

<!ELEMENT body (#PCDATA)>

<?xml version="1.0" ?>

<! DOCTYPE notes SYSTEM=“notes.dtd”>

<notes>

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

</notes>

Page 64: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT notes (note*)>

<!ELEMENT note (to, from, heading, body)>

<!ELEMENT to (#PCDATA)>

<!ELEMENT from (#PCDATA)>

<!ELEMENT heading (#PCDATA)>

<!ELEMENT body (#PCDATA)>

<?xml version="1.0" ?>

<! DOCTYPE notes SYSTEM=“notes.dtd”>

<notes>

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

</notes>

Page 65: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

<!ELEMENT notes (note*)>

<!ELEMENT note (to, from, heading, body)>

<!ELEMENT to (#PCDATA)>

<!ELEMENT from (#PCDATA)>

<!ELEMENT heading (#PCDATA)>

<!ELEMENT body (#PCDATA)>

<?xml version="1.0" ?>

<! DOCTYPE notes SYSTEM=“notes.dtd”>

<notes>

<note>

<to>Bart</to>

<from>Homer</from>

<heading>Brutto bagarospo!</heading>

<body>Ragazzo, tu hai fatto del tuo meglio e hai fallito miseramente. La lezione è: mai tentare.

</body>

</note>

</notes>

Page 66: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

XML Schema

Fare?

Page 67: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

XML non è solo web

L’xml è usato in tanti ambiti:

• Configurazione applicazioni

• Trasmissione/salvataggio di dati (serializzazione classi)

• Persistenza dei dati (Database, XQuery, XPath)

• Documentazione (DocBook)

• Immagini (SVG)

Page 68: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempio di database XML: XPeer

• Progetto del Dipartimento di Informatica.

• Prevede la creazione di un Database XML distribuito.

• Ogni nodo della rete condivide documenti in formato XML

• Da ogni nodo è possibile ricercare i documenti attraverso interrogazioni nel linguaggio XQuery.

Page 69: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Linguaggi per XML: XPath e XQuery

• XPath: linguaggio per la navigazione degli alberi XML

Esempio:

/notes/note[1]

• XQuery: linguaggio per l’interrogazione di basi di dati XML.

Esempio:

for $x in doc("notes.xml")/notes/note

where $x/to="bart"

order by $x/header

return $x/body

Page 70: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

DocBook

• Linguaggio di markup per documentazione tecnica, e non solo.

• Unica sorgente del documento in XML tante destinazioni

Page 71: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

XML DOCBOOK

HTML

LATEX

PDF

XSL FO

PDF

PS

PNG

Page 72: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempio di file DocBook

<book id="simple_book"> <title>Very simple book</title> <chapter id="simplechapter1">

<title>Chapter 1</title> <para>Hello world!</para> <para>I hope that your day is proceeding splendidly!</para>

</chapter> <chapter id="simplechapter2">

<title>Chapter 2</title> <para>Hello again, world!</para>

</chapter> </book>

Page 73: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

SVGScalable Vector Graphics

Page 74: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

I Web Client

Browser

Page 75: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

I Web Client

• Strumento per la navigazione dei siti Web.

• Nasconde i meccanismi dell’HTTP all’utente.

• In genere offre la possibilità di aprire più siti nella stessa pagina (Tabs).

Page 76: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Comunicazione Client-Server 1

1. L’utente digita l’indirizzo nel browser:

Page 77: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Comunicazione Client-Server 2

1. L’utente digita l’indirizzo nel browser:

2. Il browser richiede la pagina al Server

(in questo caso index.html):

Web Client Web Server

Page 78: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Comunicazione Client-Server 3

3. Il server ricerca il file index.html nel proprio disco e lo invia al client:

Web Client Web Server

Page 79: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Comunicazione Client-Server 4

4. Il client riceve e visualizza il file:

Page 80: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Alcuni esempi di browser

Page 81: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Firefox

Page 82: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Internet Explorer

Page 83: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Opera

Page 84: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Web Server

Page 85: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Web Server

Elabora le richieste provenienti dai Web Client:

• Richieste di pagine/immagini

• Controllo delle autorizzazioni

• Può ridirigere le richieste ad altri moduli (PHP, JSP, ASP, PLSQL)

Page 86: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Esempi di Web Server

Page 87: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Apache HTTP Web Server

Internet Information Service

Page 88: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Architetture di rete

Page 89: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Web Client Web Server

Two-tier

Page 90: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Web ClientWeb Server

DataBase

Three-tier

Page 91: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

DataBase Managment System

Page 92: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

I DBMS

• Matengono i dati (ad esempio elenco utenti, elenco prodotti)

• Permettono l’interrogazione tramite opportuni linguaggi (SQL, XQuery)

• Spesso posseggono linguaggi per la produzione di pagine html (Oracle PLSQL)

Page 93: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Alcuni DBMS

Page 94: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

PostgreSQL

Page 95: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Riferimenti

• http://www.w3.org/

• http://www.di.unipi.it/~manghi/XPeerWeb/homexpeer.htm

• http://www.docbook.org/

Page 96: mercato, società, cultura - Dipartimento di Informaticadefaveri/slides.pdf · Ragazzo, tu hai fatto del tuo meglio e . XML. Esempio: HTML PDF. Web Client Web Server ...

Siti utili

• http://www.html.it/

• http://www.w3schools.com/