SlideShare ist ein Scribd-Unternehmen logo
1 von 20
Downloaden Sie, um offline zu lesen
Introduction to
 Mobile Safari
  Alberto, Gilles and Marc
Mobile Safari
 24/10/2009




   Content

    - Introduction
    - Mobile Safari
       - GIS
       - Client-side storage
    - Demo

www.antistatique.net           2
Mobile Safari
 24/10/2009




   Introduction

    - About us
    - Web guru
    - iPhone fans
    - Symfony framework

www.antistatique.net      3
Mobile Safari
 24/10/2009




   Mobile Safari


    - CSS (animations)
    - Geolocalisation support (OS 3.x)
    - Client-Side Storage (OS 2.1)


www.antistatique.net                     4
Mobile Safari
 24/10/2009




   Geolocalisation
    navigator.geolocation.getCurrentPosition(
        successCallback,
        errorCallback,
        option
    )
www.antistatique.net                            5
navigator.geolocation.getCurrentPosition(
   function(pos){
      var lat = pos.coords.latitude;
      var lng = pos.coords.longitude;
   },
   function(error){
      switch(error.code){
        /*[...]*/
      }
   },
   {
        enableHighAccuracy: true,
        timeout: 45000, // in millisecond
        maximumAge: 60000
   };
);
Mobile Safari
 24/10/2009




   Client-side storage


    - 5 Mb
    - SQLite



www.antistatique.net     7
//// OPEN LOCAL DATABASE
var db;
if (window.openDatabase)
   db = openDatabase("as_note", "1.0", "AS Note", 200000);




//// DO A SELECT
db.transaction(function(tx) {
    tx.executeSql("SELECT id, note FROM MyTable WHERE id = ?",
[27], function(tx, rs) {
         for (var i = 0; i < rs.rows.length; ++i) {
             /* ... */
             renderNote(rs.rows.item(i));
         }
    }, function(tx, error) {
        /* ... */
    });
});
//// CREATE TABLE IF NOT EXISTS
function init()
{
    db.transaction(function(tx) {
        tx.executeSql("SELECT COUNT(*) FROM MyTable", [],
        function(result) {
            doSomething();
        }, function(tx, error) {
            tx.executeSql("CREATE TABLE MyTable (
                             id INTEGER PRIMARY KEY,
                             note TEXT,
                             timestamp REAL)", [],
            function(rs){
                doSomething();
            });
        });
    });
}
Mobile Safari
 24/10/2009




   Little web app

    - Write notes
    - Localize them
    - Do it offline
    - Take your iPhone : http://note.antistatique.net

www.antistatique.net                                    10
Mobile Safari
 24/10/2009




   Further development


    - Account system
    - Server synchronisation



www.antistatique.net           17
Mobile Safari
 24/10/2009




   Benefits of webApps


    - Easy to develop, update
    - No install required
    - Apple free ~


www.antistatique.net            18
Mobile Safari
 24/10/2009




   Backwards


    - Interactions with native apps
    - Animation
    - More


www.antistatique.net                  19
Mobile Safari
 24/10/2009




   Sources
    - http://developer.apple.com/
       - Safari and iPhone
    - http://dev.w3.org/geo/api/spec-source.html
       - Geolocation API Specification
    - http://www.w3.org/TR/offline-webapps/
       - Offline Web Applications
    - http://www.jqtouch.com/
       - plugin for mobile web development on the iPhone,
         Android, Palm Pre

www.antistatique.net                                        20

Weitere ähnliche Inhalte

Ähnlich wie Safari Mobile

Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...
 	Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W... 	Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...
Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...
Robert Nyman
 
Web APIs & Apps - Mozilla
Web APIs & Apps - MozillaWeb APIs & Apps - Mozilla
Web APIs & Apps - Mozilla
Robert Nyman
 
iPhone - web development lotus notes domino
iPhone - web development lotus notes dominoiPhone - web development lotus notes domino
iPhone - web development lotus notes domino
dominion
 
How to measure everything - a million metrics per second with minimal develop...
How to measure everything - a million metrics per second with minimal develop...How to measure everything - a million metrics per second with minimal develop...
How to measure everything - a million metrics per second with minimal develop...
Jos Boumans
 
HTML5, The Open Web, and what it means for you - MDN Hack Day, Sao Paulo
HTML5, The Open Web, and what it means for you - MDN Hack Day, Sao PauloHTML5, The Open Web, and what it means for you - MDN Hack Day, Sao Paulo
HTML5, The Open Web, and what it means for you - MDN Hack Day, Sao Paulo
Robert Nyman
 
Fixing the mobile web - Internet World Romania
Fixing the mobile web - Internet World RomaniaFixing the mobile web - Internet World Romania
Fixing the mobile web - Internet World Romania
Christian Heilmann
 
JavaScript APIs - The Web is the Platform
JavaScript APIs - The Web is the PlatformJavaScript APIs - The Web is the Platform
JavaScript APIs - The Web is the Platform
Robert Nyman
 

Ähnlich wie Safari Mobile (20)

Making your site mobile-friendly - DevCSI Reading 21.07.2010
Making your site mobile-friendly - DevCSI Reading 21.07.2010Making your site mobile-friendly - DevCSI Reading 21.07.2010
Making your site mobile-friendly - DevCSI Reading 21.07.2010
 
Øredev2013 - FirefoxOS - the platform HTML5 deserves
Øredev2013 - FirefoxOS - the platform HTML5 deservesØredev2013 - FirefoxOS - the platform HTML5 deserves
Øredev2013 - FirefoxOS - the platform HTML5 deserves
 
Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...
 	Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W... 	Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...
Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...
 
Mobile Device APIs
Mobile Device APIsMobile Device APIs
Mobile Device APIs
 
HTML5 on Mobile
HTML5 on MobileHTML5 on Mobile
HTML5 on Mobile
 
Firefox OS - HTML5 for a truly world-wide-web
Firefox OS - HTML5 for a truly world-wide-webFirefox OS - HTML5 for a truly world-wide-web
Firefox OS - HTML5 for a truly world-wide-web
 
Web APIs & Apps - Mozilla
Web APIs & Apps - MozillaWeb APIs & Apps - Mozilla
Web APIs & Apps - Mozilla
 
HTML5 WebWorks
HTML5 WebWorksHTML5 WebWorks
HTML5 WebWorks
 
Alagoas Dev Day
Alagoas Dev DayAlagoas Dev Day
Alagoas Dev Day
 
Front In Fortaleza - WebAPIs
Front In Fortaleza - WebAPIsFront In Fortaleza - WebAPIs
Front In Fortaleza - WebAPIs
 
iPhone - web development lotus notes domino
iPhone - web development lotus notes dominoiPhone - web development lotus notes domino
iPhone - web development lotus notes domino
 
Making your site mobile-friendly - Standards-Next 12.06.2010
Making your site mobile-friendly - Standards-Next 12.06.2010Making your site mobile-friendly - Standards-Next 12.06.2010
Making your site mobile-friendly - Standards-Next 12.06.2010
 
How to measure everything - a million metrics per second with minimal develop...
How to measure everything - a million metrics per second with minimal develop...How to measure everything - a million metrics per second with minimal develop...
How to measure everything - a million metrics per second with minimal develop...
 
Firefox OS
Firefox OSFirefox OS
Firefox OS
 
Always on! Or not?
Always on! Or not?Always on! Or not?
Always on! Or not?
 
HTML5, The Open Web, and what it means for you - MDN Hack Day, Sao Paulo
HTML5, The Open Web, and what it means for you - MDN Hack Day, Sao PauloHTML5, The Open Web, and what it means for you - MDN Hack Day, Sao Paulo
HTML5, The Open Web, and what it means for you - MDN Hack Day, Sao Paulo
 
Webseiten für mobile Geräte - MobileTech Conference 2010 Mainz
Webseiten für mobile Geräte - MobileTech Conference 2010 MainzWebseiten für mobile Geräte - MobileTech Conference 2010 Mainz
Webseiten für mobile Geräte - MobileTech Conference 2010 Mainz
 
Fixing the mobile web - Internet World Romania
Fixing the mobile web - Internet World RomaniaFixing the mobile web - Internet World Romania
Fixing the mobile web - Internet World Romania
 
JavaScript APIs - The Web is the Platform
JavaScript APIs - The Web is the PlatformJavaScript APIs - The Web is the Platform
JavaScript APIs - The Web is the Platform
 
Web app
Web appWeb app
Web app
 

Kürzlich hochgeladen

IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
Enterprise Knowledge
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 

Kürzlich hochgeladen (20)

Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 

Safari Mobile

  • 1. Introduction to Mobile Safari Alberto, Gilles and Marc
  • 2. Mobile Safari 24/10/2009 Content - Introduction - Mobile Safari - GIS - Client-side storage - Demo www.antistatique.net 2
  • 3. Mobile Safari 24/10/2009 Introduction - About us - Web guru - iPhone fans - Symfony framework www.antistatique.net 3
  • 4. Mobile Safari 24/10/2009 Mobile Safari - CSS (animations) - Geolocalisation support (OS 3.x) - Client-Side Storage (OS 2.1) www.antistatique.net 4
  • 5. Mobile Safari 24/10/2009 Geolocalisation navigator.geolocation.getCurrentPosition( successCallback, errorCallback, option ) www.antistatique.net 5
  • 6. navigator.geolocation.getCurrentPosition( function(pos){ var lat = pos.coords.latitude; var lng = pos.coords.longitude; }, function(error){ switch(error.code){ /*[...]*/ } }, { enableHighAccuracy: true, timeout: 45000, // in millisecond maximumAge: 60000 }; );
  • 7. Mobile Safari 24/10/2009 Client-side storage - 5 Mb - SQLite www.antistatique.net 7
  • 8. //// OPEN LOCAL DATABASE var db; if (window.openDatabase) db = openDatabase("as_note", "1.0", "AS Note", 200000); //// DO A SELECT db.transaction(function(tx) { tx.executeSql("SELECT id, note FROM MyTable WHERE id = ?", [27], function(tx, rs) { for (var i = 0; i < rs.rows.length; ++i) { /* ... */ renderNote(rs.rows.item(i)); } }, function(tx, error) { /* ... */ }); });
  • 9. //// CREATE TABLE IF NOT EXISTS function init() { db.transaction(function(tx) { tx.executeSql("SELECT COUNT(*) FROM MyTable", [], function(result) { doSomething(); }, function(tx, error) { tx.executeSql("CREATE TABLE MyTable ( id INTEGER PRIMARY KEY, note TEXT, timestamp REAL)", [], function(rs){ doSomething(); }); }); }); }
  • 10. Mobile Safari 24/10/2009 Little web app - Write notes - Localize them - Do it offline - Take your iPhone : http://note.antistatique.net www.antistatique.net 10
  • 11.
  • 12.
  • 13.
  • 14.
  • 15.
  • 16.
  • 17. Mobile Safari 24/10/2009 Further development - Account system - Server synchronisation www.antistatique.net 17
  • 18. Mobile Safari 24/10/2009 Benefits of webApps - Easy to develop, update - No install required - Apple free ~ www.antistatique.net 18
  • 19. Mobile Safari 24/10/2009 Backwards - Interactions with native apps - Animation - More www.antistatique.net 19
  • 20. Mobile Safari 24/10/2009 Sources - http://developer.apple.com/ - Safari and iPhone - http://dev.w3.org/geo/api/spec-source.html - Geolocation API Specification - http://www.w3.org/TR/offline-webapps/ - Offline Web Applications - http://www.jqtouch.com/ - plugin for mobile web development on the iPhone, Android, Palm Pre www.antistatique.net 20