SlideShare ist ein Scribd-Unternehmen logo
1 von 31
iPhone Web Development

         Prabhu
   prabhu@prabhu-s.com
Newbie questions
• Can iPhone display normal html pages?
  – Yes


• Then why do I need this session?
Non-iPhone Friendly Website
• Example
Problems with non-iPhone
             friendliness?
• Links are very close to each other.
  – Can’t tap correctly with a finger.
• Non-usable unless the page is zoomed.
iPhone Friendly Websites
• Examples
Know your iPhone
• Has desktop-class Web Browser – Safari/419.3
  (Almost Safari 3)
• (X) HTML and Canvas
• CSS 2.1 and limited CSS 3
• AJAX
• PDF, Doc & Quicktime
• Upto 8 virtual tabs
• New firmware 1.1.3 supports Bookmarklets – tiny
  icons of your website (exact view) on the Home
  Screen.
Not supported
•   Flash
•   Java
•   Embedded Audio/Video
•   Drag and Drop
•   File upload
•   JS execution > 5 sec
•   Html > 10 Mb
Levels of iPhone support
• iPhone Compatible – No flash, use
  quicktime
• iPhone Friendly – Simple CSS fixes
• iPhone Optimized - Use only features
  supported by safari.
• iPhone Webapps – Simulate native
  applications.
Get started
• Detect iPhone in your html code
  if (navigator.userAgent.indexOf('iPhone') != -1) {
      //iPhone
  }
  else {
      // Normal browser
  }

• Use Different style sheet
 <LINK rel=quot;stylesheetquot; media=quot;only screen and (max-device-
 width:480px)“ href=“url” />
Get started (Contd)
• Set Viewport meta tag
 <meta name=quot;viewportquot; content=quot;width=320; initial-scale=1.0;
 maximum-scale=1.0; user-scalable=0;quot;>
Development Process
• Write normal html code.
• Follow guidelines in
  http://developer.apple.com/iphone
• Use Safari for testing out your site.
  Then test it in iPhone.
• iPhoney for mac (www.iphoney.com)
  provides an iPhone emulator.
Integrate with Phone
• tel:9841405319 – Tap to call
• mailto:prabhu@prabhu-s.com – Email
• http://maps.google.com – Opens
  Google Map
• http://www.youtube.com – Opens
  Youtube
Emulate native apps
• Fix your stylesheet to match colors and
  size of UI elements
• Every new page should appear with a
  horizontal slide.
• Should not display blank page when the
  page is getting loaded. (AJAX!)
• Example
How to code?
• Write a Javascript to do the sliding.
• Don’t display blank page. Always load a
  page using AJAX.
• Before loading the page call the
  Javascript for horizontal slide.
Any framework?
• Use iUi (http://code.google.com/p/iui/)
• Simply include iUi.css and iUi.js in your
  html!
iUi Features
                       Nav Headers

                       Navigational Menus



• Build Nav headers using canvas tag
• Create Navigational menus from JSON
• Provides a more “iPhone-like”
  experience to Web apps.
Examples
• Canvas and “iPhone-like” UI elements.
Canvas tag
• Canvas tag can be used to render
  graphics or other visual images on the
  fly.
• Example
• No documentation as to how much of
  this functionality is supported by iPhone!
iPhone-like UI Element
      Code for Toggle type Button

      <div class=“toggle” toggled=“false”>
        <span class=“toggleOn”>ON</span>
        <span class=“toggleOff”>OFF</span>
      </div>

      Grouping of Elements

      <fieldset>
         <input type=“text” name=“userName”/>
          // Other text fields
      </fieldset>
Audio/Video support
• Audio – Mp3, aac
• Video – mov, mp4, m4v, 3gp
• Use reference movies
• Make sure your HTTP server supports
  byte-range requests.
• Provide direct links to the contents.
Known Issues
• Mouse, Keyboard events
  – Fire inconsistently
• Form events
  – onsubmit, oninput fires inconsistently
• Zooming, dragging
  – onfocus, onblur getting called
    unnecessarily!
• window.onresize – very buggy
What about native apps?
• Apple supposed to release an official
  SDK this month.
• Or Hack your phone and install the 3rd
  party apps available.
  – Process called as Jail Breaking!
• Languages like Python, Ruby already
  ported!
Few native apps
What’s next?
• Join the iphoneindia google group
  (http://groups.google.com/group/iphonei
  ndia)
• Check out www.iphonewebdev.com
• How about iPhoneDevCamp in India?
Thanks!
Q&A Anyone?

Weitere ähnliche Inhalte

Was ist angesagt?

From desktop to mobile web
From desktop to mobile webFrom desktop to mobile web
From desktop to mobile web
Chris Love
 

Was ist angesagt? (19)

Effective guide to remove filmate search.com
Effective guide to remove filmate search.comEffective guide to remove filmate search.com
Effective guide to remove filmate search.com
 
Bruce Lawson: Progressive Web Apps: the future of Apps
Bruce Lawson: Progressive Web Apps: the future of AppsBruce Lawson: Progressive Web Apps: the future of Apps
Bruce Lawson: Progressive Web Apps: the future of Apps
 
WebMatrix jQuery Mobile Web
WebMatrix jQuery Mobile WebWebMatrix jQuery Mobile Web
WebMatrix jQuery Mobile Web
 
10 things to make you a Great Mobile Web Developer
10 things to make you a Great Mobile Web Developer10 things to make you a Great Mobile Web Developer
10 things to make you a Great Mobile Web Developer
 
From desktop to mobile web
From desktop to mobile webFrom desktop to mobile web
From desktop to mobile web
 
How To Be an HTML5 Mobile Cloud Champion
How To Be an HTML5 Mobile Cloud ChampionHow To Be an HTML5 Mobile Cloud Champion
How To Be an HTML5 Mobile Cloud Champion
 
15 things you should know about BA (En)
15 things you should know about BA  (En)15 things you should know about BA  (En)
15 things you should know about BA (En)
 
Cheaponomics
CheaponomicsCheaponomics
Cheaponomics
 
#UseThePlatfom - Levando suas aplicações ao próximo nível com Polymer
#UseThePlatfom - Levando suas aplicações ao próximo nível com Polymer#UseThePlatfom - Levando suas aplicações ao próximo nível com Polymer
#UseThePlatfom - Levando suas aplicações ao próximo nível com Polymer
 
CLAS Mobile View and Recording Interface
CLAS Mobile View and Recording InterfaceCLAS Mobile View and Recording Interface
CLAS Mobile View and Recording Interface
 
Recreating mobile controls in mobile web apps
Recreating mobile controls in mobile web appsRecreating mobile controls in mobile web apps
Recreating mobile controls in mobile web apps
 
How to present like a Pro with Anymeeting
How to present like a Pro with AnymeetingHow to present like a Pro with Anymeeting
How to present like a Pro with Anymeeting
 
Blackberry
BlackberryBlackberry
Blackberry
 
Php2pdf
Php2pdfPhp2pdf
Php2pdf
 
Doing Modern Web, aka JavaScript and HTML5 in the Enterprise
Doing Modern Web, aka JavaScript and HTML5 in the EnterpriseDoing Modern Web, aka JavaScript and HTML5 in the Enterprise
Doing Modern Web, aka JavaScript and HTML5 in the Enterprise
 
WordPress Biratnagar Meetup #1Wordpress Installation : By Sajjal Neupane
WordPress Biratnagar Meetup #1Wordpress Installation : By Sajjal NeupaneWordPress Biratnagar Meetup #1Wordpress Installation : By Sajjal Neupane
WordPress Biratnagar Meetup #1Wordpress Installation : By Sajjal Neupane
 
Joomla Installation
Joomla InstallationJoomla Installation
Joomla Installation
 
Video de amor
Video de amor Video de amor
Video de amor
 
iPhone & Android App Dev - BarCamp Saigon 1
iPhone & Android App Dev - BarCamp Saigon 1iPhone & Android App Dev - BarCamp Saigon 1
iPhone & Android App Dev - BarCamp Saigon 1
 

Ähnlich wie iPhone Web Applications Development - Prabhu

MozTW YZU CSE Lecture
MozTW YZU CSE LectureMozTW YZU CSE Lecture
MozTW YZU CSE Lecture
littlebtc
 
Ajax Tutorial
Ajax TutorialAjax Tutorial
Ajax Tutorial
oscon2007
 
Mobile Meow at Mobilism
Mobile Meow at MobilismMobile Meow at Mobilism
Mobile Meow at Mobilism
Greg Schechter
 
iPhone Development For Experienced Web Developers
iPhone Development For Experienced Web DevelopersiPhone Development For Experienced Web Developers
iPhone Development For Experienced Web Developers
lisab517
 
Getting started with PhoneGap
Getting started with PhoneGapGetting started with PhoneGap
Getting started with PhoneGap
Mihai Corlan
 
Maximiliano Firtman - Разработка приложений с помощью PhoneGap
Maximiliano Firtman - Разработка приложений с помощью PhoneGap Maximiliano Firtman - Разработка приложений с помощью PhoneGap
Maximiliano Firtman - Разработка приложений с помощью PhoneGap
.toster
 
Responsive web design & mobile web development - a technical and business app...
Responsive web design & mobile web development - a technical and business app...Responsive web design & mobile web development - a technical and business app...
Responsive web design & mobile web development - a technical and business app...
Atos_Worldline
 
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)
Fabien Potencier
 

Ähnlich wie iPhone Web Applications Development - Prabhu (20)

MozTW YZU CSE Lecture
MozTW YZU CSE LectureMozTW YZU CSE Lecture
MozTW YZU CSE Lecture
 
Performance Improvements in Browsers
Performance Improvements in BrowsersPerformance Improvements in Browsers
Performance Improvements in Browsers
 
Ajax Tutorial
Ajax TutorialAjax Tutorial
Ajax Tutorial
 
SmartPhone Design and Delivery
SmartPhone Design and DeliverySmartPhone Design and Delivery
SmartPhone Design and Delivery
 
Mobile Meow at Mobilism
Mobile Meow at MobilismMobile Meow at Mobilism
Mobile Meow at Mobilism
 
Debugging and Tuning Mobile Web Sites with Modern Web Browsers
Debugging and Tuning Mobile Web Sites with Modern Web BrowsersDebugging and Tuning Mobile Web Sites with Modern Web Browsers
Debugging and Tuning Mobile Web Sites with Modern Web Browsers
 
JS Days Mobile Meow
JS Days Mobile MeowJS Days Mobile Meow
JS Days Mobile Meow
 
The future is hybrid
The future is hybridThe future is hybrid
The future is hybrid
 
Web DU Mobile Meow
Web DU Mobile MeowWeb DU Mobile Meow
Web DU Mobile Meow
 
iPhone Development For Experienced Web Developers
iPhone Development For Experienced Web DevelopersiPhone Development For Experienced Web Developers
iPhone Development For Experienced Web Developers
 
Getting started with PhoneGap
Getting started with PhoneGapGetting started with PhoneGap
Getting started with PhoneGap
 
PhoneGap mobile development
PhoneGap mobile developmentPhoneGap mobile development
PhoneGap mobile development
 
Maximiliano Firtman - Разработка приложений с помощью PhoneGap
Maximiliano Firtman - Разработка приложений с помощью PhoneGap Maximiliano Firtman - Разработка приложений с помощью PhoneGap
Maximiliano Firtman - Разработка приложений с помощью PhoneGap
 
Eye candy for your iPhone
Eye candy for your iPhoneEye candy for your iPhone
Eye candy for your iPhone
 
Performance, Games, and Distributed Testing in JavaScript
Performance, Games, and Distributed Testing in JavaScriptPerformance, Games, and Distributed Testing in JavaScript
Performance, Games, and Distributed Testing in JavaScript
 
Mobile html5 today
Mobile html5 todayMobile html5 today
Mobile html5 today
 
Whats New In Silverlight 3
Whats New In Silverlight 3Whats New In Silverlight 3
Whats New In Silverlight 3
 
Responsive web design & mobile web development - a technical and business app...
Responsive web design & mobile web development - a technical and business app...Responsive web design & mobile web development - a technical and business app...
Responsive web design & mobile web development - a technical and business app...
 
Skill Session - Web Multi Device
Skill Session - Web Multi DeviceSkill Session - Web Multi Device
Skill Session - Web Multi Device
 
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)
 

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
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 

Kürzlich hochgeladen (20)

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
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
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
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
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
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
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
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
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
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
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
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
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
 
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
 

iPhone Web Applications Development - Prabhu

  • 1. iPhone Web Development Prabhu prabhu@prabhu-s.com
  • 2. Newbie questions • Can iPhone display normal html pages? – Yes • Then why do I need this session?
  • 4.
  • 5.
  • 6. Problems with non-iPhone friendliness? • Links are very close to each other. – Can’t tap correctly with a finger. • Non-usable unless the page is zoomed.
  • 8.
  • 9.
  • 10. Know your iPhone • Has desktop-class Web Browser – Safari/419.3 (Almost Safari 3) • (X) HTML and Canvas • CSS 2.1 and limited CSS 3 • AJAX • PDF, Doc & Quicktime • Upto 8 virtual tabs • New firmware 1.1.3 supports Bookmarklets – tiny icons of your website (exact view) on the Home Screen.
  • 11. Not supported • Flash • Java • Embedded Audio/Video • Drag and Drop • File upload • JS execution > 5 sec • Html > 10 Mb
  • 12. Levels of iPhone support • iPhone Compatible – No flash, use quicktime • iPhone Friendly – Simple CSS fixes • iPhone Optimized - Use only features supported by safari. • iPhone Webapps – Simulate native applications.
  • 13. Get started • Detect iPhone in your html code if (navigator.userAgent.indexOf('iPhone') != -1) { //iPhone } else { // Normal browser } • Use Different style sheet <LINK rel=quot;stylesheetquot; media=quot;only screen and (max-device- width:480px)“ href=“url” />
  • 14. Get started (Contd) • Set Viewport meta tag <meta name=quot;viewportquot; content=quot;width=320; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;quot;>
  • 15. Development Process • Write normal html code. • Follow guidelines in http://developer.apple.com/iphone • Use Safari for testing out your site. Then test it in iPhone. • iPhoney for mac (www.iphoney.com) provides an iPhone emulator.
  • 16. Integrate with Phone • tel:9841405319 – Tap to call • mailto:prabhu@prabhu-s.com – Email • http://maps.google.com – Opens Google Map • http://www.youtube.com – Opens Youtube
  • 17. Emulate native apps • Fix your stylesheet to match colors and size of UI elements • Every new page should appear with a horizontal slide. • Should not display blank page when the page is getting loaded. (AJAX!) • Example
  • 18.
  • 19.
  • 20. How to code? • Write a Javascript to do the sliding. • Don’t display blank page. Always load a page using AJAX. • Before loading the page call the Javascript for horizontal slide.
  • 21. Any framework? • Use iUi (http://code.google.com/p/iui/) • Simply include iUi.css and iUi.js in your html!
  • 22. iUi Features Nav Headers Navigational Menus • Build Nav headers using canvas tag • Create Navigational menus from JSON • Provides a more “iPhone-like” experience to Web apps.
  • 23. Examples • Canvas and “iPhone-like” UI elements.
  • 24. Canvas tag • Canvas tag can be used to render graphics or other visual images on the fly. • Example • No documentation as to how much of this functionality is supported by iPhone!
  • 25. iPhone-like UI Element Code for Toggle type Button <div class=“toggle” toggled=“false”> <span class=“toggleOn”>ON</span> <span class=“toggleOff”>OFF</span> </div> Grouping of Elements <fieldset> <input type=“text” name=“userName”/> // Other text fields </fieldset>
  • 26. Audio/Video support • Audio – Mp3, aac • Video – mov, mp4, m4v, 3gp • Use reference movies • Make sure your HTTP server supports byte-range requests. • Provide direct links to the contents.
  • 27. Known Issues • Mouse, Keyboard events – Fire inconsistently • Form events – onsubmit, oninput fires inconsistently • Zooming, dragging – onfocus, onblur getting called unnecessarily! • window.onresize – very buggy
  • 28. What about native apps? • Apple supposed to release an official SDK this month. • Or Hack your phone and install the 3rd party apps available. – Process called as Jail Breaking! • Languages like Python, Ruby already ported!
  • 30. What’s next? • Join the iphoneindia google group (http://groups.google.com/group/iphonei ndia) • Check out www.iphonewebdev.com • How about iPhoneDevCamp in India?