O'Reilly logo

Sencha Touch Cookbook - Second Edition by Ajit Kumar

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Capturing and managing photos using a camera

This recipe is going to show how you can pull out the photos from your phone or capture a live photo and use it in your application.

Getting ready

Make sure that you have set up your development environment by following the recipes outlined in Chapter 1, Gear Up for the Journey.

Create a new folder ch10 inside the www folder. We will be using this new folder to keep the code.

How to do it...

Follow the ensuing steps:

  1. Create and open a new file ch10_01.js and paste the following code in it:
    Ext.application({ name : 'MyApp', //this is a must as it is not part of the standard package requires: ['Ext.device.Camera'], launch: function() { //template to show the photos var tpl = new Ext.XTemplate( '<tpl for=".">', ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required