Lexique Langages & Documents Réfs Paul Franchi SI 4 2011-12 Techs Sommaire . . . . . . 12/09/2011 Transparent - 1 Chap IX - RDF Resource Description Framework Chap IX - RDF Resource Description Framework Chap X - AJAX Asynchronous JavaScript And XML Chap X - AJAX Asynchronous JavaScript And XML
30
Embed
Lexique Sommaire - users.polytech.unice.frusers.polytech.unice.fr/~pfz/LANGDOC/COURS/10_11_RDF_AJAX.pdf · Chap VII - XSD: Schémas XML Chap VIII - XML "Advanced" Processeurs et Dialectes:
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Communication par RDF files (génération par Php, etc.)
RSS 1.0
Dublin Core MetaData
OWL
Mozilla
contents.rdf
chrome.rdf
XUL
Communication par RDF files (génération par Php, etc.)
RSS 1.0
Lexique
Réfs
Techs
RDF- Resource Description Framework (source W3C)
"Request" sur un serveur (url, .asp ou.php)
RDF -W3C SyntaxValidator & Graph Generator
Dublin Core
RDF: Bag, Seq, Alt
RDF - Graphe Entité-Relation
OWL - "Web Ontology Language " (source W3C)
"Request" sur un document .xml
RDF/XML –Resource withProperties and Values
AJAX- AsynchronousJavaScript and XML
Objet xmlHttpRequest
Sommaire
Transparent 1612/09/2011
Dublin Core
The Dublin Core Metadata Initiative (DCMI) has created some predefined properties for describing documents.
The Dublin Core Metadata Initiative (DCMI) has created some predefined properties for describing documents.
Property DefinitionContributor An entity responsible for making contributions to the content of the resource
Coverage The extent or scope of the content of the resource
Creator An entity primarily responsible for making the content of the resource
Format The physical or digital manifestation of the resource
Date A date of an event in the lifecycle of the resource
Description An account of the content of the resource
Identifier An unambiguous reference to the resource within a given context
Language A language of the intellectual content of the resource
Publisher An entity responsible for making the resource available
Relation A reference to a related resource
Rights Information about rights held in and over the resource
Source A Reference to a resource from which the present resource is derived
Subject A topic of the content of the resource
Title A name given to the resource
Type The nature or genre of the content of the resource
Lexique
Réfs
Techs
RDF- Resource Description Framework (source W3C)
"Request" sur un serveur (url, .asp ou.php)
RDF -W3C SyntaxValidator & Graph Generator
Dublin Core
RDF: Bag, Seq, Alt
RDF - Graphe Entité-Relation
OWL - "Web Ontology Language " (source W3C)
"Request" sur un document .xml
RDF/XML –Resource withProperties and Values
AJAX- AsynchronousJavaScript and XML
Objet xmlHttpRequest
Sommaire
Transparent 1712/09/2011
Dublin Core
<?xml version="1.0" encoding="ISO-8859-1"?><!-- RDF file pour le Tutorial de W3Schools--><rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
AJAX is not a new programming language, but a technique for creating better, faster, and more interactive web applications.
With AJAX, your JavaScript can communicate directly with the server, using the JavaScript XMLHttpRequest object. With this object, your JavaScript can trade data with a web server, without reloading the page.
AJAX uses asynchronous data transfer (HTTP requests) between the browser and the web server, allowing web pages to request small bits of information from the server instead of whole pages.
The AJAX technique makes Internet applications smaller, faster and more user-friendly.
AJAX is a browser technology independent of web server software.
AJAX is based on the following web standards:
JavaScript
XML
HTML
CSS
AJAX is not a new programming language, but a technique for creating better, faster, and more interactive web applications.
With AJAX, your JavaScript can communicate directly with the server, using the JavaScript XMLHttpRequest object. With this object, your JavaScript can trade data with a web server, without reloading the page.
AJAX uses asynchronous data transfer (HTTP requests) between the browser and the web server, allowing web pages to request small bits of information from the server instead of whole pages.
The AJAX technique makes Internet applications smaller, faster and more user-friendly.
AJAX is a browser technology independent of web server software.
AJAX is based on the following web standards:
JavaScript
XML
HTML
CSS
Lexique
Réfs
Techs
RDF- Resource Description Framework (source W3C)
"Request" sur un serveur (url, .asp ou.php)
RDF -W3C SyntaxValidator & Graph Generator
Dublin Core
RDF: Bag, Seq, Alt
RDF - Graphe Entité-Relation
OWL - "Web Ontology Language " (source W3C)
"Request" sur un document .xml
RDF/XML –Resource withProperties and Values
AJAX- AsynchronousJavaScript and XML
Objet xmlHttpRequest
Sommaire
Transparent 2112/09/2011
<html><script type="text/javascript">
function HTTP() {
}</script><body>
HTTP() ;
</body> </html>
Côté "Client"
Côté "Serveur"
AJAX : schéma "HttpRequest / Response"
Lexique
Réfs
Techs
RDF- Resource Description Framework (source W3C)
"Request" sur un serveur (url, .asp ou.php)
RDF -W3C SyntaxValidator & Graph Generator
Dublin Core
RDF: Bag, Seq, Alt
RDF - Graphe Entité-Relation
OWL - "Web Ontology Language " (source W3C)
"Request" sur un document .xml
RDF/XML –Resource withProperties and Values
AJAX- AsynchronousJavaScript and XML
Objet xmlHttpRequest
Sommaire
Transparent 2212/09/2011
L'Objet XMLHttpRequest
Attributs
readyState
status 200 si ok - 404 si la page n'est pas trouvée.
responseText données chargées dans une chaîne de caractères.
responseXml données chargées sous forme xml,
onreadystatechange propriété activée par un évènement de changement d'état. On lui assigne une fonction.
Méthodes
open(mode, url, boolean)
mode: type de requête, GET ou POST
url: l'adresse des données,
boolean: true (asynchrone) / false (synchrone).
en option on peut ajouter un login et un mot de passe.
send("chaine") null pour une commande GET.
Attributs
readyState
status 200 si ok - 404 si la page n'est pas trouvée.
responseText données chargées dans une chaîne de caractères.
responseXml données chargées sous forme xml,
onreadystatechange propriété activée par un évènement de changement d'état. On lui assigne une fonction.
Méthodes
open(mode, url, boolean)
mode: type de requête, GET ou POST
url: l'adresse des données,
boolean: true (asynchrone) / false (synchrone).
en option on peut ajouter un login et un mot de passe.
else if (window.ActiveXObject) { // code for IE5, IE6xmlhttp = new ActiveXObject ("Microsoft.XMLHTTP");}
if (xmlhttp!=null) {xmlhttp.onreadystatechange = onResponse;xmlhttp.open ("GET", url, true);xmlhttp.send (null);}
else { alert ("Your browser does not support XMLHTTP."); }}
XMLHttpRequest asynchrone: onResponse()
XMLHttpRequest asynchrone: onResponse()
"Request" sur un document .xml
Lexique
Réfs
Techs
RDF- Resource Description Framework (source W3C)
"Request" sur un serveur (url, .asp ou.php)
RDF -W3C SyntaxValidator & Graph Generator
Dublin Core
RDF: Bag, Seq, Alt
RDF - Graphe Entité-Relation
OWL - "Web Ontology Language " (source W3C)
"Request" sur un document .xml
RDF/XML –Resource withProperties and Values
AJAX- AsynchronousJavaScript and XML
Objet xmlHttpRequest
Sommaire
Transparent 2812/09/2011
function onResponse(){if (xmlhttp.readyState!=4) return;if (xmlhttp.status!=0 && xmlhttp.status!=200) // OK?
{alert ("Problem retrieving XML data");return;}
TRAITEMENT_DU_XML() ; // ou TRAITEMENT_DU_TEXTE()}]]></script></head><body><div id="copy"><button onclick="loadXMLDoc('cd_catalog.xml')">Get CD info</button></div> </body>
XMLHttpRequest asynchrone: onResponse()
XMLHttpRequest asynchrone: onResponse()
"Request" sur un document .xml
Lexique
Réfs
Techs
RDF- Resource Description Framework (source W3C)
"Request" sur un serveur (url, .asp ou.php)
RDF -W3C SyntaxValidator & Graph Generator
Dublin Core
RDF: Bag, Seq, Alt
RDF - Graphe Entité-Relation
OWL - "Web Ontology Language " (source W3C)
"Request" sur un document .xml
RDF/XML –Resource withProperties and Values
AJAX- AsynchronousJavaScript and XML
Objet xmlHttpRequest
Sommaire
Transparent 2912/09/2011
TRAITEMENT_DU_TEXTE() {
// extraction du "string source"var reponse = xmlhttp.responseText ;
/******* traitement avec RegExp, match(), split(), substr(), slice(), etc.
****/
var debut=new RegExp ("[\\d\\D]*?<\/CD>");alert (xmlhttp.responseText.match(debut)[0]) ;