SlideShare ist ein Scribd-Unternehmen logo
1 von 34
Downloaden Sie, um offline zu lesen
Curso HTML5 y el
Futuro de la Web
  Aplicaciones Web
   19 de Julio 2012
     Jose María Álvarez Rodríguez
     WESO-Universidad de Oviedo
    E-mail: josem.alvarez@weso.es
     WWW: http://josemalvarez.es
Conceptos Clave

Diseño y Estilo   Audio y Vídeo


   Dibujar         Rich-Apps



Geolocalización     Semántica
Aplicación Web

Aplicación cuyo acceso se realiza a
través de los protocolos propios de
              Internet.
…Y en HTML5



      Lo mismo
(JS+CSS+…) pero más
  elegante y abierto
HTML5 en acción
    Data Storage
Aplicaciones off-line
Comunicación con el
    servidor web
Data Storage
    Servidor
  Lógica de negocio


     Cliente
     Preferencias
Estado de la aplicación
Data Storage

 El nombre de storage no es del todo
adecuado ya que no se almacena en la
                web.
Antecedentes
Data Storage
                    Session
                       Temporal
       Sólo mientras la página está abierta

                       Local
                     Permanente
  Algunos navegadores permiten su gestión
http://dev.w3.org/html5/webstorage/ (Actualizado 10/07/2012
Data Storage
   Es una base de datos clave/valor:

 localStorage[“clave”]= valor
  localStorage.clave = valor


localStorage["user_name"] =
nameInput.value;
alert(“Nombre: " +
localStorage["user_name"]);
Características
• En general de 5MB (según
  navegador) hasta 50MB
• Privacidad (datos se pueden)
  • Bloquear
  • Caducar
  • Tratar como cookies
  • Blacklists, etc.
Soporte
Navegador Mínimo

Internet Explorer 8

Firefox 3.5
Google Chrome 5

Apple Safari 4

Opera 10.5
Tipos de Datos
ID              Expresión


Strings         localStorage.clave = valor


Números         edad = Number(localStorage[“edad”]);

Fechas          sessionStorage[“fecha"] = new Date();


Objetos         sessionStore[“persona"] =
                JSON.stringify(p);

Ficheros        FileAPI: FileReader(); readAsText();
(operaciones)   readAsBinaryString()
                Múltiples ficheros: atributo multiple en elemento input
Operaciones
Tipo             Expresión


Borrar un ítem   localStorage.removeItem("user_name");



Borrar todos     sessionStorage.clear();

Buscar todos     for (var i=0; i<localStorage.length; i++) {
                   var key = localStorage.key(i);
                   var item = localStorage[key]; }

…                …


Evento           window.onload = function() {
                    window.addEventListener("storage",
                 storageChanged, false);
                 };
Tarea 1
Crear una página que lea un nombre y lo
    almacene en local y en la sesión.
       Comprobar que funciona
         (cerrar y abrir página)


Ver: cursoHtml5/aplicaciones-web/ejemplos/t1.html
Tarea 2

    Leer y mostrar el contenido de un
                 fichero.



Ver: cursoHtml5/aplicaciones-web/ejemplos/t2.html
Tarea 3

   Arrastrar y mostrar una fotografía en
              una página web.



Ver: cursoHtml5/aplicaciones-web/ejemplos/t3.html
Aplicaciones off-line
       Stateful
    Interactivas
Depende de usuarios
      objetivos
http://www.w3.org/TR/offline-webapps/
Pasos para convertir en
            off-line

1.    Crear un fichero de texto manifest
2.    Indicar en la página el uso del
      manifest
3.    Configurar el servidor para el tipo
      mime del manifest
          text/cache-manifest
Ejemplo
CACHE MANIFEST                  Se descargan los ficheros:
index.html
                            •     Páginas HTML
results.html                •     Archivos CSS
                            •     Scripts con lógica de
                                  negocio
style.css                   •     Imágenes
style_results.css


results.js
                          Referencia
arrow_left.png
                       <!DOCTYPE html>
arrow_right.png        <html lang="en"
star.png               manifest=“fichero.manifest">
Problemas Conocidos

   Descarga del fichero
       manifest
 Descarga de los ficheros
         indicados
Fichero manifest en caché
Soporte
Navegador Mínimo

Internet Explorer 8

Firefox 3.5                …hasta
Google Chrome 5             5MB

Apple Safari 4

Opera 10.6
Aplicaciones off-line
    Para hacer pruebas desactivar el
    sistema de caché del navegador.


  Se puede utilizar un script de JS para
    chequear la conexión y cargar de
            distinta forma.
Aplicaciones off-line
  Añadir fallbacks
    FALLBACK:
    *.jpg missing.jpg
    / offline.html


Añadir recursos en
        red
    NETWORK:
    imgs/logo.png
Eventos
•     onChecking
•     onNoUpdate
•     onDownloading
•     onProgress
•     onCached
•     onUpdateReady
•     onError
•     onObsolete

    No todos los navegadores ejecutan de la
                 misma forma
Tarea 4

Crear una página de las ya realizadas con
  recursos para que se ejecute off-line
Comunicación con el
    servidor web

Enviar mensajes al servidor
   Recibir mensajes del
  servidor (Server event)
       Websockets
Tarea 5
Observar el código y comportamiento de
       aplicaciones web HTML5

http://www.sudokubum.com/

http://www.html5arena.com/blog/html5/16-awesome-
examples-of-html5-applications/

https://developer.tizen.org/resources/sample-web-
applications
Resumiendo…
•   Mejora del desarrollo con
    HTML5+JS+CSS
•   Explotación de recursos en
    el cliente

       Javascript, Javascript,
           Javascript…
Conclusiones
•   HTML5 permite llevar el
    entorno de escritorio a la web
•   Mejora tecnológica
•   Basado en estándares y
    abierto
•   Computación ubicua
•   Bajo acoplamiento
•   …
Enlaces interesantes
• http://www.whatwg.org/specs/web-apps/current-
  work/multipage/offline.html
• http://www.catswhocode.com/blog/how-to-create-offline-
  html5-web-apps-in-5-easy-steps
• http://googlecode.blogspot.com.es/2009/04/gmail-for-
  mobile-html5-series-using.html
• http://jonathanstark.com/blog/2009/09/27/debugging-
  html-5-offline-application-cache/
• http://gigaom.com/collaboration/why-html5-web-apps-are-
  going-to-rock-your-world/
• http://www.w3schools.com/html5/att_html_manifest.asp
• http://www.w3schools.com/html5/html5_app_cache.asp
• http://www.w3schools.com/html5/html5_webstorage.asp
Curso HTML5 y el
Futuro de la Web
  Aplicaciones Web
   19 de Julio 2012
     Jose María Álvarez Rodríguez
     WESO-Universidad de Oviedo
    E-mail: josem.alvarez@weso.es
     WWW: http://josemalvarez.es

Weitere ähnliche Inhalte

Was ist angesagt?

Cómo puedo trabajar con una página web si no tengo conexión a internet
Cómo puedo trabajar con una página web si no tengo conexión a internetCómo puedo trabajar con una página web si no tengo conexión a internet
Cómo puedo trabajar con una página web si no tengo conexión a internetCRAER de Molina
 
Proyecto de Topicos II - HTML5
Proyecto de Topicos II - HTML5Proyecto de Topicos II - HTML5
Proyecto de Topicos II - HTML5joycesita
 
Presentacion generalidades
Presentacion generalidadesPresentacion generalidades
Presentacion generalidadesmiguel angel
 
Escritorios virtuais
Escritorios virtuaisEscritorios virtuais
Escritorios virtuaisxoanca
 
Pagina web en línea
Pagina web en líneaPagina web en línea
Pagina web en líneaKpg1311
 
318847501 paginas-web
318847501 paginas-web318847501 paginas-web
318847501 paginas-webAstrid Valdes
 
Lecciones aprendidas creando una red social
Lecciones aprendidas creando una red socialLecciones aprendidas creando una red social
Lecciones aprendidas creando una red socialRoberto Luis Bisbé
 

Was ist angesagt? (16)

Ajax
AjaxAjax
Ajax
 
Plataforma WEB
Plataforma WEBPlataforma WEB
Plataforma WEB
 
Paginas web y Blogs
Paginas web y BlogsPaginas web y Blogs
Paginas web y Blogs
 
Cómo puedo trabajar con una página web si no tengo conexión a internet
Cómo puedo trabajar con una página web si no tengo conexión a internetCómo puedo trabajar con una página web si no tengo conexión a internet
Cómo puedo trabajar con una página web si no tengo conexión a internet
 
Paginas web
Paginas webPaginas web
Paginas web
 
Proyecto de Topicos II - HTML5
Proyecto de Topicos II - HTML5Proyecto de Topicos II - HTML5
Proyecto de Topicos II - HTML5
 
Presentacion generalidades
Presentacion generalidadesPresentacion generalidades
Presentacion generalidades
 
Generalidades
GeneralidadesGeneralidades
Generalidades
 
Esquemas
EsquemasEsquemas
Esquemas
 
Html5
Html5Html5
Html5
 
Escritorios virtuais
Escritorios virtuaisEscritorios virtuais
Escritorios virtuais
 
Pagina web en línea
Pagina web en líneaPagina web en línea
Pagina web en línea
 
Dala
DalaDala
Dala
 
Bootstrap menues, contenedores y formularios
Bootstrap   menues, contenedores y formulariosBootstrap   menues, contenedores y formularios
Bootstrap menues, contenedores y formularios
 
318847501 paginas-web
318847501 paginas-web318847501 paginas-web
318847501 paginas-web
 
Lecciones aprendidas creando una red social
Lecciones aprendidas creando una red socialLecciones aprendidas creando una red social
Lecciones aprendidas creando una red social
 

Andere mochten auch (14)

Introducción a Sistemas de Información
Introducción a Sistemas de InformaciónIntroducción a Sistemas de Información
Introducción a Sistemas de Información
 
HTML5 Audio & Vídeo
HTML5 Audio & VídeoHTML5 Audio & Vídeo
HTML5 Audio & Vídeo
 
Internet, Web 2.0 y Salud 2.0
Internet, Web 2.0 y Salud 2.0Internet, Web 2.0 y Salud 2.0
Internet, Web 2.0 y Salud 2.0
 
Ejemplos prácticos de Búsqueda en Salud
Ejemplos prácticos de Búsqueda en SaludEjemplos prácticos de Búsqueda en Salud
Ejemplos prácticos de Búsqueda en Salud
 
Introducción a "La Web como una Base de Datos"
Introducción a "La Web como una Base de Datos"Introducción a "La Web como una Base de Datos"
Introducción a "La Web como una Base de Datos"
 
CORFU-MTSR 2013
CORFU-MTSR 2013CORFU-MTSR 2013
CORFU-MTSR 2013
 
Simple Presentation for Slideshare
Simple Presentation for SlideshareSimple Presentation for Slideshare
Simple Presentation for Slideshare
 
Scalable Data Analysis in R Webinar Presentation
Scalable Data Analysis in R Webinar PresentationScalable Data Analysis in R Webinar Presentation
Scalable Data Analysis in R Webinar Presentation
 
MOLDEAS-PhD Summary
MOLDEAS-PhD SummaryMOLDEAS-PhD Summary
MOLDEAS-PhD Summary
 
Researching Semantic Web-Overview
Researching Semantic Web-OverviewResearching Semantic Web-Overview
Researching Semantic Web-Overview
 
QoS Management in Cloud Computing-Draft proposal
QoS Management in Cloud Computing-Draft proposalQoS Management in Cloud Computing-Draft proposal
QoS Management in Cloud Computing-Draft proposal
 
WP4-QoS Management in the Cloud
WP4-QoS Management in the CloudWP4-QoS Management in the Cloud
WP4-QoS Management in the Cloud
 
MOLDEAS at City College
MOLDEAS at City CollegeMOLDEAS at City College
MOLDEAS at City College
 
Map/Reduce intro
Map/Reduce introMap/Reduce intro
Map/Reduce intro
 

Ähnlich wie HTML5-Aplicaciones web

HTML5 Almacenamiento - Montiu octubre 2013 - Universidad Móstoles (ES)
HTML5 Almacenamiento - Montiu octubre 2013 - Universidad Móstoles (ES)HTML5 Almacenamiento - Montiu octubre 2013 - Universidad Móstoles (ES)
HTML5 Almacenamiento - Montiu octubre 2013 - Universidad Móstoles (ES)Santiago Montiu Torguet
 
Entendiendo Yii - Flisol 2016
Entendiendo Yii - Flisol 2016Entendiendo Yii - Flisol 2016
Entendiendo Yii - Flisol 2016Plattinux
 
Presentación html5
Presentación html5Presentación html5
Presentación html5aydimdagam
 
Html5 - El futuro de la web
Html5 - El futuro de la webHtml5 - El futuro de la web
Html5 - El futuro de la webJoan Fernández
 
Webinar interlat apps_2012_carlos_a-perez_españa
Webinar interlat apps_2012_carlos_a-perez_españaWebinar interlat apps_2012_carlos_a-perez_españa
Webinar interlat apps_2012_carlos_a-perez_españaJerilee Dueñas Rengifo
 
Webinar interlat apps_2012_carlos_a-perez_españa
Webinar interlat apps_2012_carlos_a-perez_españaWebinar interlat apps_2012_carlos_a-perez_españa
Webinar interlat apps_2012_carlos_a-perez_españaCommunity Managers Latam
 
APPS Aplicaciones móviles: Construyendo y publicando nuestro primera APPS mul...
APPS Aplicaciones móviles: Construyendo y publicando nuestro primera APPS mul...APPS Aplicaciones móviles: Construyendo y publicando nuestro primera APPS mul...
APPS Aplicaciones móviles: Construyendo y publicando nuestro primera APPS mul...Interlat
 
Un poco más allá con grails. PrimerViernes
Un poco más allá con grails. PrimerViernesUn poco más allá con grails. PrimerViernes
Un poco más allá con grails. PrimerViernesDani Latorre
 
Primeros pasos Symfony PHPVigo
Primeros pasos Symfony PHPVigoPrimeros pasos Symfony PHPVigo
Primeros pasos Symfony PHPVigoPHP Vigo
 
Mi querido navegador web ¿Qué sabe de mí?
Mi querido navegador web ¿Qué sabe de mí?Mi querido navegador web ¿Qué sabe de mí?
Mi querido navegador web ¿Qué sabe de mí?linenoise
 
IT Camps Apps Office 365 Valencia 2014
IT Camps Apps Office 365 Valencia 2014IT Camps Apps Office 365 Valencia 2014
IT Camps Apps Office 365 Valencia 2014Adrian Diaz Cervera
 
Curso de Desarrollo Web de Platzi
Curso de Desarrollo Web de PlatziCurso de Desarrollo Web de Platzi
Curso de Desarrollo Web de PlatziCarlos Azaustre
 
Seminario jquery, html5 y wicket
Seminario jquery, html5 y wicketSeminario jquery, html5 y wicket
Seminario jquery, html5 y wicketAdrià Solé Orrit
 

Ähnlich wie HTML5-Aplicaciones web (20)

HTML5 Almacenamiento - Montiu octubre 2013 - Universidad Móstoles (ES)
HTML5 Almacenamiento - Montiu octubre 2013 - Universidad Móstoles (ES)HTML5 Almacenamiento - Montiu octubre 2013 - Universidad Móstoles (ES)
HTML5 Almacenamiento - Montiu octubre 2013 - Universidad Móstoles (ES)
 
Introducción a HTML5
Introducción a HTML5Introducción a HTML5
Introducción a HTML5
 
HTML5
HTML5HTML5
HTML5
 
Entendiendo Yii - Flisol 2016
Entendiendo Yii - Flisol 2016Entendiendo Yii - Flisol 2016
Entendiendo Yii - Flisol 2016
 
Presentación html5
Presentación html5Presentación html5
Presentación html5
 
El Nuevo Internet Explorer 9
El Nuevo Internet Explorer 9El Nuevo Internet Explorer 9
El Nuevo Internet Explorer 9
 
Html5 - El futuro de la web
Html5 - El futuro de la webHtml5 - El futuro de la web
Html5 - El futuro de la web
 
JavaScript
JavaScriptJavaScript
JavaScript
 
Webinar interlat apps_2012_carlos_a-perez_españa
Webinar interlat apps_2012_carlos_a-perez_españaWebinar interlat apps_2012_carlos_a-perez_españa
Webinar interlat apps_2012_carlos_a-perez_españa
 
Webinar interlat apps_2012_carlos_a-perez_españa
Webinar interlat apps_2012_carlos_a-perez_españaWebinar interlat apps_2012_carlos_a-perez_españa
Webinar interlat apps_2012_carlos_a-perez_españa
 
APPS Aplicaciones móviles: Construyendo y publicando nuestro primera APPS mul...
APPS Aplicaciones móviles: Construyendo y publicando nuestro primera APPS mul...APPS Aplicaciones móviles: Construyendo y publicando nuestro primera APPS mul...
APPS Aplicaciones móviles: Construyendo y publicando nuestro primera APPS mul...
 
Un poco más allá con grails. PrimerViernes
Un poco más allá con grails. PrimerViernesUn poco más allá con grails. PrimerViernes
Un poco más allá con grails. PrimerViernes
 
Primeros pasos Symfony PHPVigo
Primeros pasos Symfony PHPVigoPrimeros pasos Symfony PHPVigo
Primeros pasos Symfony PHPVigo
 
Mi querido navegador web ¿Qué sabe de mí?
Mi querido navegador web ¿Qué sabe de mí?Mi querido navegador web ¿Qué sabe de mí?
Mi querido navegador web ¿Qué sabe de mí?
 
JqueryMobile
JqueryMobile JqueryMobile
JqueryMobile
 
IT Camps Apps Office 365 Valencia 2014
IT Camps Apps Office 365 Valencia 2014IT Camps Apps Office 365 Valencia 2014
IT Camps Apps Office 365 Valencia 2014
 
Curso de Desarrollo Web de Platzi
Curso de Desarrollo Web de PlatziCurso de Desarrollo Web de Platzi
Curso de Desarrollo Web de Platzi
 
Seminario jquery, html5 y wicket
Seminario jquery, html5 y wicketSeminario jquery, html5 y wicket
Seminario jquery, html5 y wicket
 
J query
J queryJ query
J query
 
Plantilla ppt
Plantilla pptPlantilla ppt
Plantilla ppt
 

Mehr von CARLOS III UNIVERSITY OF MADRID

Engineering 4.0: Digitization through task automation and reuse
Engineering 4.0:  Digitization through task automation and reuseEngineering 4.0:  Digitization through task automation and reuse
Engineering 4.0: Digitization through task automation and reuseCARLOS III UNIVERSITY OF MADRID
 
LOTAR-PDES: Engineering digitalization through task automation and reuse in t...
LOTAR-PDES: Engineering digitalization through task automation and reuse in t...LOTAR-PDES: Engineering digitalization through task automation and reuse in t...
LOTAR-PDES: Engineering digitalization through task automation and reuse in t...CARLOS III UNIVERSITY OF MADRID
 
Sailing the V: Engineering digitalization through task automation and reuse i...
Sailing the V: Engineering digitalization through task automation and reuse i...Sailing the V: Engineering digitalization through task automation and reuse i...
Sailing the V: Engineering digitalization through task automation and reuse i...CARLOS III UNIVERSITY OF MADRID
 
AI4SE: Challenges and opportunities in the integration of Systems Engineering...
AI4SE: Challenges and opportunities in the integration of Systems Engineering...AI4SE: Challenges and opportunities in the integration of Systems Engineering...
AI4SE: Challenges and opportunities in the integration of Systems Engineering...CARLOS III UNIVERSITY OF MADRID
 
Challenges in the integration of Systems Engineering and the AI/ML model life...
Challenges in the integration of Systems Engineering and the AI/ML model life...Challenges in the integration of Systems Engineering and the AI/ML model life...
Challenges in the integration of Systems Engineering and the AI/ML model life...CARLOS III UNIVERSITY OF MADRID
 
OSLC KM: Elevating the meaning of data and operations within the toolchain
OSLC KM: Elevating the meaning of data and operations within the toolchainOSLC KM: Elevating the meaning of data and operations within the toolchain
OSLC KM: Elevating the meaning of data and operations within the toolchainCARLOS III UNIVERSITY OF MADRID
 
OSLC KM (Knowledge Management): elevating the meaning of data and operations ...
OSLC KM (Knowledge Management): elevating the meaning of data and operations ...OSLC KM (Knowledge Management): elevating the meaning of data and operations ...
OSLC KM (Knowledge Management): elevating the meaning of data and operations ...CARLOS III UNIVERSITY OF MADRID
 
Systems and Software Architecture: an introduction to architectural modelling
Systems and Software Architecture: an introduction to architectural modellingSystems and Software Architecture: an introduction to architectural modelling
Systems and Software Architecture: an introduction to architectural modellingCARLOS III UNIVERSITY OF MADRID
 
Detection of fraud in financial blockchain-based transactions through big dat...
Detection of fraud in financial blockchain-based transactions through big dat...Detection of fraud in financial blockchain-based transactions through big dat...
Detection of fraud in financial blockchain-based transactions through big dat...CARLOS III UNIVERSITY OF MADRID
 
News headline generation with sentiment and patterns: A case study of sports ...
News headline generation with sentiment and patterns: A case study of sports ...News headline generation with sentiment and patterns: A case study of sports ...
News headline generation with sentiment and patterns: A case study of sports ...CARLOS III UNIVERSITY OF MADRID
 

Mehr von CARLOS III UNIVERSITY OF MADRID (20)

Proyecto IVERES-UC3M
Proyecto IVERES-UC3MProyecto IVERES-UC3M
Proyecto IVERES-UC3M
 
RTVE: Sustainable Development Goal Radar
RTVE: Sustainable Development Goal  RadarRTVE: Sustainable Development Goal  Radar
RTVE: Sustainable Development Goal Radar
 
Engineering 4.0: Digitization through task automation and reuse
Engineering 4.0:  Digitization through task automation and reuseEngineering 4.0:  Digitization through task automation and reuse
Engineering 4.0: Digitization through task automation and reuse
 
LOTAR-PDES: Engineering digitalization through task automation and reuse in t...
LOTAR-PDES: Engineering digitalization through task automation and reuse in t...LOTAR-PDES: Engineering digitalization through task automation and reuse in t...
LOTAR-PDES: Engineering digitalization through task automation and reuse in t...
 
SESE 2021: Where Systems Engineering meets AI/ML
SESE 2021: Where Systems Engineering meets AI/MLSESE 2021: Where Systems Engineering meets AI/ML
SESE 2021: Where Systems Engineering meets AI/ML
 
Sailing the V: Engineering digitalization through task automation and reuse i...
Sailing the V: Engineering digitalization through task automation and reuse i...Sailing the V: Engineering digitalization through task automation and reuse i...
Sailing the V: Engineering digitalization through task automation and reuse i...
 
Deep Learning Notes
Deep Learning NotesDeep Learning Notes
Deep Learning Notes
 
H2020-AHTOOLS Use Case 3 Functional Design
H2020-AHTOOLS Use Case 3 Functional DesignH2020-AHTOOLS Use Case 3 Functional Design
H2020-AHTOOLS Use Case 3 Functional Design
 
AI4SE: Challenges and opportunities in the integration of Systems Engineering...
AI4SE: Challenges and opportunities in the integration of Systems Engineering...AI4SE: Challenges and opportunities in the integration of Systems Engineering...
AI4SE: Challenges and opportunities in the integration of Systems Engineering...
 
INCOSE IS 2019: AI and Systems Engineering
INCOSE IS 2019: AI and Systems EngineeringINCOSE IS 2019: AI and Systems Engineering
INCOSE IS 2019: AI and Systems Engineering
 
Challenges in the integration of Systems Engineering and the AI/ML model life...
Challenges in the integration of Systems Engineering and the AI/ML model life...Challenges in the integration of Systems Engineering and the AI/ML model life...
Challenges in the integration of Systems Engineering and the AI/ML model life...
 
Blockchain en la Industria Musical
Blockchain en la Industria MusicalBlockchain en la Industria Musical
Blockchain en la Industria Musical
 
OSLC KM: Elevating the meaning of data and operations within the toolchain
OSLC KM: Elevating the meaning of data and operations within the toolchainOSLC KM: Elevating the meaning of data and operations within the toolchain
OSLC KM: Elevating the meaning of data and operations within the toolchain
 
Blockchain y sector asegurador
Blockchain y sector aseguradorBlockchain y sector asegurador
Blockchain y sector asegurador
 
OSLC KM (Knowledge Management): elevating the meaning of data and operations ...
OSLC KM (Knowledge Management): elevating the meaning of data and operations ...OSLC KM (Knowledge Management): elevating the meaning of data and operations ...
OSLC KM (Knowledge Management): elevating the meaning of data and operations ...
 
Systems and Software Architecture: an introduction to architectural modelling
Systems and Software Architecture: an introduction to architectural modellingSystems and Software Architecture: an introduction to architectural modelling
Systems and Software Architecture: an introduction to architectural modelling
 
Detection of fraud in financial blockchain-based transactions through big dat...
Detection of fraud in financial blockchain-based transactions through big dat...Detection of fraud in financial blockchain-based transactions through big dat...
Detection of fraud in financial blockchain-based transactions through big dat...
 
News headline generation with sentiment and patterns: A case study of sports ...
News headline generation with sentiment and patterns: A case study of sports ...News headline generation with sentiment and patterns: A case study of sports ...
News headline generation with sentiment and patterns: A case study of sports ...
 
Blockchain y la industria musical
Blockchain y la industria musicalBlockchain y la industria musical
Blockchain y la industria musical
 
Preparing your Big Data start-up pitch
Preparing your Big Data start-up pitchPreparing your Big Data start-up pitch
Preparing your Big Data start-up pitch
 

Kürzlich hochgeladen

Avances tecnológicos del siglo XXI 10-07 eyvana
Avances tecnológicos del siglo XXI 10-07 eyvanaAvances tecnológicos del siglo XXI 10-07 eyvana
Avances tecnológicos del siglo XXI 10-07 eyvanamcerpam
 
PROYECTO FINAL. Tutorial para publicar en SlideShare.pptx
PROYECTO FINAL. Tutorial para publicar en SlideShare.pptxPROYECTO FINAL. Tutorial para publicar en SlideShare.pptx
PROYECTO FINAL. Tutorial para publicar en SlideShare.pptxAlan779941
 
EL CICLO PRÁCTICO DE UN MOTOR DE CUATRO TIEMPOS.pptx
EL CICLO PRÁCTICO DE UN MOTOR DE CUATRO TIEMPOS.pptxEL CICLO PRÁCTICO DE UN MOTOR DE CUATRO TIEMPOS.pptx
EL CICLO PRÁCTICO DE UN MOTOR DE CUATRO TIEMPOS.pptxMiguelAtencio10
 
Refrigerador_Inverter_Samsung_Curso_y_Manual_de_Servicio_Español.pdf
Refrigerador_Inverter_Samsung_Curso_y_Manual_de_Servicio_Español.pdfRefrigerador_Inverter_Samsung_Curso_y_Manual_de_Servicio_Español.pdf
Refrigerador_Inverter_Samsung_Curso_y_Manual_de_Servicio_Español.pdfvladimiroflores1
 
Resistencia extrema al cobre por un consorcio bacteriano conformado por Sulfo...
Resistencia extrema al cobre por un consorcio bacteriano conformado por Sulfo...Resistencia extrema al cobre por un consorcio bacteriano conformado por Sulfo...
Resistencia extrema al cobre por un consorcio bacteriano conformado por Sulfo...JohnRamos830530
 
pruebas unitarias unitarias en java con JUNIT
pruebas unitarias unitarias en java con JUNITpruebas unitarias unitarias en java con JUNIT
pruebas unitarias unitarias en java con JUNITMaricarmen Sánchez Ruiz
 
Avances tecnológicos del siglo XXI y ejemplos de estos
Avances tecnológicos del siglo XXI y ejemplos de estosAvances tecnológicos del siglo XXI y ejemplos de estos
Avances tecnológicos del siglo XXI y ejemplos de estossgonzalezp1
 
Innovaciones tecnologicas en el siglo 21
Innovaciones tecnologicas en el siglo 21Innovaciones tecnologicas en el siglo 21
Innovaciones tecnologicas en el siglo 21mariacbr99
 
EPA-pdf resultado da prova presencial Uninove
EPA-pdf resultado da prova presencial UninoveEPA-pdf resultado da prova presencial Uninove
EPA-pdf resultado da prova presencial UninoveFagnerLisboa3
 
Modulo-Mini Cargador.................pdf
Modulo-Mini Cargador.................pdfModulo-Mini Cargador.................pdf
Modulo-Mini Cargador.................pdfAnnimoUno1
 
How to use Redis with MuleSoft. A quick start presentation.
How to use Redis with MuleSoft. A quick start presentation.How to use Redis with MuleSoft. A quick start presentation.
How to use Redis with MuleSoft. A quick start presentation.FlorenciaCattelani
 

Kürzlich hochgeladen (11)

Avances tecnológicos del siglo XXI 10-07 eyvana
Avances tecnológicos del siglo XXI 10-07 eyvanaAvances tecnológicos del siglo XXI 10-07 eyvana
Avances tecnológicos del siglo XXI 10-07 eyvana
 
PROYECTO FINAL. Tutorial para publicar en SlideShare.pptx
PROYECTO FINAL. Tutorial para publicar en SlideShare.pptxPROYECTO FINAL. Tutorial para publicar en SlideShare.pptx
PROYECTO FINAL. Tutorial para publicar en SlideShare.pptx
 
EL CICLO PRÁCTICO DE UN MOTOR DE CUATRO TIEMPOS.pptx
EL CICLO PRÁCTICO DE UN MOTOR DE CUATRO TIEMPOS.pptxEL CICLO PRÁCTICO DE UN MOTOR DE CUATRO TIEMPOS.pptx
EL CICLO PRÁCTICO DE UN MOTOR DE CUATRO TIEMPOS.pptx
 
Refrigerador_Inverter_Samsung_Curso_y_Manual_de_Servicio_Español.pdf
Refrigerador_Inverter_Samsung_Curso_y_Manual_de_Servicio_Español.pdfRefrigerador_Inverter_Samsung_Curso_y_Manual_de_Servicio_Español.pdf
Refrigerador_Inverter_Samsung_Curso_y_Manual_de_Servicio_Español.pdf
 
Resistencia extrema al cobre por un consorcio bacteriano conformado por Sulfo...
Resistencia extrema al cobre por un consorcio bacteriano conformado por Sulfo...Resistencia extrema al cobre por un consorcio bacteriano conformado por Sulfo...
Resistencia extrema al cobre por un consorcio bacteriano conformado por Sulfo...
 
pruebas unitarias unitarias en java con JUNIT
pruebas unitarias unitarias en java con JUNITpruebas unitarias unitarias en java con JUNIT
pruebas unitarias unitarias en java con JUNIT
 
Avances tecnológicos del siglo XXI y ejemplos de estos
Avances tecnológicos del siglo XXI y ejemplos de estosAvances tecnológicos del siglo XXI y ejemplos de estos
Avances tecnológicos del siglo XXI y ejemplos de estos
 
Innovaciones tecnologicas en el siglo 21
Innovaciones tecnologicas en el siglo 21Innovaciones tecnologicas en el siglo 21
Innovaciones tecnologicas en el siglo 21
 
EPA-pdf resultado da prova presencial Uninove
EPA-pdf resultado da prova presencial UninoveEPA-pdf resultado da prova presencial Uninove
EPA-pdf resultado da prova presencial Uninove
 
Modulo-Mini Cargador.................pdf
Modulo-Mini Cargador.................pdfModulo-Mini Cargador.................pdf
Modulo-Mini Cargador.................pdf
 
How to use Redis with MuleSoft. A quick start presentation.
How to use Redis with MuleSoft. A quick start presentation.How to use Redis with MuleSoft. A quick start presentation.
How to use Redis with MuleSoft. A quick start presentation.
 

HTML5-Aplicaciones web

  • 1. Curso HTML5 y el Futuro de la Web Aplicaciones Web 19 de Julio 2012 Jose María Álvarez Rodríguez WESO-Universidad de Oviedo E-mail: josem.alvarez@weso.es WWW: http://josemalvarez.es
  • 2. Conceptos Clave Diseño y Estilo Audio y Vídeo Dibujar Rich-Apps Geolocalización Semántica
  • 3. Aplicación Web Aplicación cuyo acceso se realiza a través de los protocolos propios de Internet.
  • 4. …Y en HTML5 Lo mismo (JS+CSS+…) pero más elegante y abierto
  • 5. HTML5 en acción Data Storage Aplicaciones off-line Comunicación con el servidor web
  • 6. Data Storage Servidor Lógica de negocio Cliente Preferencias Estado de la aplicación
  • 7. Data Storage El nombre de storage no es del todo adecuado ya que no se almacena en la web.
  • 9. Data Storage Session Temporal Sólo mientras la página está abierta Local Permanente Algunos navegadores permiten su gestión http://dev.w3.org/html5/webstorage/ (Actualizado 10/07/2012
  • 10. Data Storage Es una base de datos clave/valor: localStorage[“clave”]= valor localStorage.clave = valor localStorage["user_name"] = nameInput.value; alert(“Nombre: " + localStorage["user_name"]);
  • 11. Características • En general de 5MB (según navegador) hasta 50MB • Privacidad (datos se pueden) • Bloquear • Caducar • Tratar como cookies • Blacklists, etc.
  • 12.
  • 13. Soporte Navegador Mínimo Internet Explorer 8 Firefox 3.5 Google Chrome 5 Apple Safari 4 Opera 10.5
  • 14. Tipos de Datos ID Expresión Strings localStorage.clave = valor Números edad = Number(localStorage[“edad”]); Fechas sessionStorage[“fecha"] = new Date(); Objetos sessionStore[“persona"] = JSON.stringify(p); Ficheros FileAPI: FileReader(); readAsText(); (operaciones) readAsBinaryString() Múltiples ficheros: atributo multiple en elemento input
  • 15. Operaciones Tipo Expresión Borrar un ítem localStorage.removeItem("user_name"); Borrar todos sessionStorage.clear(); Buscar todos for (var i=0; i<localStorage.length; i++) { var key = localStorage.key(i); var item = localStorage[key]; } … … Evento window.onload = function() { window.addEventListener("storage", storageChanged, false); };
  • 16. Tarea 1 Crear una página que lea un nombre y lo almacene en local y en la sesión. Comprobar que funciona (cerrar y abrir página) Ver: cursoHtml5/aplicaciones-web/ejemplos/t1.html
  • 17. Tarea 2 Leer y mostrar el contenido de un fichero. Ver: cursoHtml5/aplicaciones-web/ejemplos/t2.html
  • 18. Tarea 3 Arrastrar y mostrar una fotografía en una página web. Ver: cursoHtml5/aplicaciones-web/ejemplos/t3.html
  • 19. Aplicaciones off-line Stateful Interactivas Depende de usuarios objetivos http://www.w3.org/TR/offline-webapps/
  • 20. Pasos para convertir en off-line 1. Crear un fichero de texto manifest 2. Indicar en la página el uso del manifest 3. Configurar el servidor para el tipo mime del manifest text/cache-manifest
  • 21. Ejemplo CACHE MANIFEST Se descargan los ficheros: index.html • Páginas HTML results.html • Archivos CSS • Scripts con lógica de negocio style.css • Imágenes style_results.css results.js Referencia arrow_left.png <!DOCTYPE html> arrow_right.png <html lang="en" star.png manifest=“fichero.manifest">
  • 22. Problemas Conocidos Descarga del fichero manifest Descarga de los ficheros indicados Fichero manifest en caché
  • 23. Soporte Navegador Mínimo Internet Explorer 8 Firefox 3.5 …hasta Google Chrome 5 5MB Apple Safari 4 Opera 10.6
  • 24. Aplicaciones off-line Para hacer pruebas desactivar el sistema de caché del navegador. Se puede utilizar un script de JS para chequear la conexión y cargar de distinta forma.
  • 25. Aplicaciones off-line Añadir fallbacks FALLBACK: *.jpg missing.jpg / offline.html Añadir recursos en red NETWORK: imgs/logo.png
  • 26. Eventos • onChecking • onNoUpdate • onDownloading • onProgress • onCached • onUpdateReady • onError • onObsolete No todos los navegadores ejecutan de la misma forma
  • 27. Tarea 4 Crear una página de las ya realizadas con recursos para que se ejecute off-line
  • 28. Comunicación con el servidor web Enviar mensajes al servidor Recibir mensajes del servidor (Server event) Websockets
  • 29. Tarea 5 Observar el código y comportamiento de aplicaciones web HTML5 http://www.sudokubum.com/ http://www.html5arena.com/blog/html5/16-awesome- examples-of-html5-applications/ https://developer.tizen.org/resources/sample-web- applications
  • 30. Resumiendo… • Mejora del desarrollo con HTML5+JS+CSS • Explotación de recursos en el cliente Javascript, Javascript, Javascript…
  • 31. Conclusiones • HTML5 permite llevar el entorno de escritorio a la web • Mejora tecnológica • Basado en estándares y abierto • Computación ubicua • Bajo acoplamiento • …
  • 32. Enlaces interesantes • http://www.whatwg.org/specs/web-apps/current- work/multipage/offline.html • http://www.catswhocode.com/blog/how-to-create-offline- html5-web-apps-in-5-easy-steps • http://googlecode.blogspot.com.es/2009/04/gmail-for- mobile-html5-series-using.html • http://jonathanstark.com/blog/2009/09/27/debugging- html-5-offline-application-cache/ • http://gigaom.com/collaboration/why-html5-web-apps-are- going-to-rock-your-world/ • http://www.w3schools.com/html5/att_html_manifest.asp • http://www.w3schools.com/html5/html5_app_cache.asp • http://www.w3schools.com/html5/html5_webstorage.asp
  • 33.
  • 34. Curso HTML5 y el Futuro de la Web Aplicaciones Web 19 de Julio 2012 Jose María Álvarez Rodríguez WESO-Universidad de Oviedo E-mail: josem.alvarez@weso.es WWW: http://josemalvarez.es