Enviar pesquisa
Carregar
PHP goes mobile
•
4 gostaram
•
3,306 visualizações
Enrico Zimuel
Seguir
Sviluppo di applicazioni web mobile con Zend Framework
Leia menos
Leia mais
Relação com investidores
Tecnologia
Denunciar
Compartilhar
Denunciar
Compartilhar
1 de 24
Baixar agora
Baixar para ler offline
Recomendados
Zend Framework 2
Zend Framework 2
Enrico Zimuel
Framework software e Zend Framework
Framework software e Zend Framework
Enrico Zimuel
Velocizzare Joomla! con Zend Server Community Edition
Velocizzare Joomla! con Zend Server Community Edition
Enrico Zimuel
Integrare Zend Framework in Wordpress
Integrare Zend Framework in Wordpress
Enrico Zimuel
Il Pattern di Zend Framework 2
Il Pattern di Zend Framework 2
Zend by Rogue Wave Software
Il testing con zend framework
Il testing con zend framework
Zend by Rogue Wave Software
Closure Visto Da Vicino
Closure Visto Da Vicino
davide ficano
Simone Carletti: Zend Framework ed i Web Service
Simone Carletti: Zend Framework ed i Web Service
Francesco Fullone
Recomendados
Zend Framework 2
Zend Framework 2
Enrico Zimuel
Framework software e Zend Framework
Framework software e Zend Framework
Enrico Zimuel
Velocizzare Joomla! con Zend Server Community Edition
Velocizzare Joomla! con Zend Server Community Edition
Enrico Zimuel
Integrare Zend Framework in Wordpress
Integrare Zend Framework in Wordpress
Enrico Zimuel
Il Pattern di Zend Framework 2
Il Pattern di Zend Framework 2
Zend by Rogue Wave Software
Il testing con zend framework
Il testing con zend framework
Zend by Rogue Wave Software
Closure Visto Da Vicino
Closure Visto Da Vicino
davide ficano
Simone Carletti: Zend Framework ed i Web Service
Simone Carletti: Zend Framework ed i Web Service
Francesco Fullone
XCheck a benchmark checker for XML query processors
XCheck a benchmark checker for XML query processors
Enrico Zimuel
Introduzione alla Posta Elettronica Certificata (PEC): le regole tecniche
Introduzione alla Posta Elettronica Certificata (PEC): le regole tecniche
Enrico Zimuel
Manage cloud infrastructures in PHP using Zend Framework 2 (and 1)
Manage cloud infrastructures in PHP using Zend Framework 2 (and 1)
Enrico Zimuel
La sicurezza delle applicazioni in PHP
La sicurezza delle applicazioni in PHP
Enrico Zimuel
Introduzione alla crittografia
Introduzione alla crittografia
Enrico Zimuel
Crittografia quantistica: fantascienza o realtà?
Crittografia quantistica: fantascienza o realtà?
Enrico Zimuel
Introduzione alle tabelle hash
Introduzione alle tabelle hash
Enrico Zimuel
Enrico Zimuel: La sicurezza delle applicazioni in PHP
Enrico Zimuel: La sicurezza delle applicazioni in PHP
Francesco Fullone
Crittografia è sinonimo di sicurezza?
Crittografia è sinonimo di sicurezza?
Enrico Zimuel
L'ABC della crittografia
L'ABC della crittografia
Giovanni Bechis
Sesta parte sicurezza_in_rete
Sesta parte sicurezza_in_rete
Zilli Emilio
How does TOR work and what is the DeepWeb
How does TOR work and what is the DeepWeb
Gianluca Gabrielli
Cryptography with Zend Framework
Cryptography with Zend Framework
Enrico Zimuel
Crittografia
Crittografia
FRANCA SORMANI
Crittografia
Crittografia
Andrea Gottardi
Principi di crittografia
Principi di crittografia
peppespe
Crittografia
Crittografia
Mionome
Cryptography in PHP: use cases
Cryptography in PHP: use cases
Enrico Zimuel
Manage cloud infrastructures using Zend Framework 2 (and ZF1)
Manage cloud infrastructures using Zend Framework 2 (and ZF1)
Enrico Zimuel
Strong cryptography in PHP
Strong cryptography in PHP
Enrico Zimuel
Il testing con zend framework
Il testing con zend framework
Zend by Rogue Wave Software
Case study: un approccio modulare in un progetto legacy
Case study: un approccio modulare in un progetto legacy
Mariano Fiorentino
Mais conteúdo relacionado
Destaque
XCheck a benchmark checker for XML query processors
XCheck a benchmark checker for XML query processors
Enrico Zimuel
Introduzione alla Posta Elettronica Certificata (PEC): le regole tecniche
Introduzione alla Posta Elettronica Certificata (PEC): le regole tecniche
Enrico Zimuel
Manage cloud infrastructures in PHP using Zend Framework 2 (and 1)
Manage cloud infrastructures in PHP using Zend Framework 2 (and 1)
Enrico Zimuel
La sicurezza delle applicazioni in PHP
La sicurezza delle applicazioni in PHP
Enrico Zimuel
Introduzione alla crittografia
Introduzione alla crittografia
Enrico Zimuel
Crittografia quantistica: fantascienza o realtà?
Crittografia quantistica: fantascienza o realtà?
Enrico Zimuel
Introduzione alle tabelle hash
Introduzione alle tabelle hash
Enrico Zimuel
Enrico Zimuel: La sicurezza delle applicazioni in PHP
Enrico Zimuel: La sicurezza delle applicazioni in PHP
Francesco Fullone
Crittografia è sinonimo di sicurezza?
Crittografia è sinonimo di sicurezza?
Enrico Zimuel
L'ABC della crittografia
L'ABC della crittografia
Giovanni Bechis
Sesta parte sicurezza_in_rete
Sesta parte sicurezza_in_rete
Zilli Emilio
How does TOR work and what is the DeepWeb
How does TOR work and what is the DeepWeb
Gianluca Gabrielli
Cryptography with Zend Framework
Cryptography with Zend Framework
Enrico Zimuel
Crittografia
Crittografia
FRANCA SORMANI
Crittografia
Crittografia
Andrea Gottardi
Principi di crittografia
Principi di crittografia
peppespe
Crittografia
Crittografia
Mionome
Cryptography in PHP: use cases
Cryptography in PHP: use cases
Enrico Zimuel
Manage cloud infrastructures using Zend Framework 2 (and ZF1)
Manage cloud infrastructures using Zend Framework 2 (and ZF1)
Enrico Zimuel
Strong cryptography in PHP
Strong cryptography in PHP
Enrico Zimuel
Destaque
(20)
XCheck a benchmark checker for XML query processors
XCheck a benchmark checker for XML query processors
Introduzione alla Posta Elettronica Certificata (PEC): le regole tecniche
Introduzione alla Posta Elettronica Certificata (PEC): le regole tecniche
Manage cloud infrastructures in PHP using Zend Framework 2 (and 1)
Manage cloud infrastructures in PHP using Zend Framework 2 (and 1)
La sicurezza delle applicazioni in PHP
La sicurezza delle applicazioni in PHP
Introduzione alla crittografia
Introduzione alla crittografia
Crittografia quantistica: fantascienza o realtà?
Crittografia quantistica: fantascienza o realtà?
Introduzione alle tabelle hash
Introduzione alle tabelle hash
Enrico Zimuel: La sicurezza delle applicazioni in PHP
Enrico Zimuel: La sicurezza delle applicazioni in PHP
Crittografia è sinonimo di sicurezza?
Crittografia è sinonimo di sicurezza?
L'ABC della crittografia
L'ABC della crittografia
Sesta parte sicurezza_in_rete
Sesta parte sicurezza_in_rete
How does TOR work and what is the DeepWeb
How does TOR work and what is the DeepWeb
Cryptography with Zend Framework
Cryptography with Zend Framework
Crittografia
Crittografia
Crittografia
Crittografia
Principi di crittografia
Principi di crittografia
Crittografia
Crittografia
Cryptography in PHP: use cases
Cryptography in PHP: use cases
Manage cloud infrastructures using Zend Framework 2 (and ZF1)
Manage cloud infrastructures using Zend Framework 2 (and ZF1)
Strong cryptography in PHP
Strong cryptography in PHP
Semelhante a PHP goes mobile
Il testing con zend framework
Il testing con zend framework
Zend by Rogue Wave Software
Case study: un approccio modulare in un progetto legacy
Case study: un approccio modulare in un progetto legacy
Mariano Fiorentino
Non Conventional Android Programming (Italiano)
Non Conventional Android Programming (Italiano)
Davide Cerbo
Come sviluppare applicazioni cross device con HTML
Come sviluppare applicazioni cross device con HTML
Sinergia Totale
Pro php refactoring
Pro php refactoring
Francesco Trucchia
Slide Mulesoft Meetup Milano #10.pdf
Slide Mulesoft Meetup Milano #10.pdf
Florence Consulting
App Engine + Python
App Engine + Python
Simone Marzola
Csp@scuola smarttv corso1
Csp@scuola smarttv corso1
CSP Scarl
Sicurezza Php (giugno 2010) Stefano Bianchini presso Ce.Se.N.A.
Sicurezza Php (giugno 2010) Stefano Bianchini presso Ce.Se.N.A.
Stefano Bianchini
Android - ishan fernando - android nfc presentation
Android - ishan fernando - android nfc presentation
Whymca
Whymca nfc presentation
Whymca nfc presentation
Myti S.r.l.
Whymca nfc presentation
Whymca nfc presentation
Myti S.r.l.
Hexagonal architecture ita
Hexagonal architecture ita
Alessandro Minoccheri
Simple Cloud API: accesso semplificato al cloud computing
Simple Cloud API: accesso semplificato al cloud computing
Francesca1980
Codice efficiente per le Windows Store Apps by Matteo Anelli
Codice efficiente per le Windows Store Apps by Matteo Anelli
Codemotion
Alla scoperta di Zend Framework 1.8
Alla scoperta di Zend Framework 1.8
massimiliano.wosz
Il Web orientato al futuro: Express, Angular e nodeJS
Il Web orientato al futuro: Express, Angular e nodeJS
Eugenio Minardi
Programmazione mobile: ANDROID
Programmazione mobile: ANDROID
Paolo Tosato
introduzione a symfony 2
introduzione a symfony 2
Riccardo Franconi
WEBdeBS NFC Presentation
WEBdeBS NFC Presentation
Myti S.r.l.
Semelhante a PHP goes mobile
(20)
Il testing con zend framework
Il testing con zend framework
Case study: un approccio modulare in un progetto legacy
Case study: un approccio modulare in un progetto legacy
Non Conventional Android Programming (Italiano)
Non Conventional Android Programming (Italiano)
Come sviluppare applicazioni cross device con HTML
Come sviluppare applicazioni cross device con HTML
Pro php refactoring
Pro php refactoring
Slide Mulesoft Meetup Milano #10.pdf
Slide Mulesoft Meetup Milano #10.pdf
App Engine + Python
App Engine + Python
Csp@scuola smarttv corso1
Csp@scuola smarttv corso1
Sicurezza Php (giugno 2010) Stefano Bianchini presso Ce.Se.N.A.
Sicurezza Php (giugno 2010) Stefano Bianchini presso Ce.Se.N.A.
Android - ishan fernando - android nfc presentation
Android - ishan fernando - android nfc presentation
Whymca nfc presentation
Whymca nfc presentation
Whymca nfc presentation
Whymca nfc presentation
Hexagonal architecture ita
Hexagonal architecture ita
Simple Cloud API: accesso semplificato al cloud computing
Simple Cloud API: accesso semplificato al cloud computing
Codice efficiente per le Windows Store Apps by Matteo Anelli
Codice efficiente per le Windows Store Apps by Matteo Anelli
Alla scoperta di Zend Framework 1.8
Alla scoperta di Zend Framework 1.8
Il Web orientato al futuro: Express, Angular e nodeJS
Il Web orientato al futuro: Express, Angular e nodeJS
Programmazione mobile: ANDROID
Programmazione mobile: ANDROID
introduzione a symfony 2
introduzione a symfony 2
WEBdeBS NFC Presentation
WEBdeBS NFC Presentation
Mais de Enrico Zimuel
Password (in)security
Password (in)security
Enrico Zimuel
Quick start on Zend Framework 2
Quick start on Zend Framework 2
Enrico Zimuel
A quick start on Zend Framework 2
A quick start on Zend Framework 2
Enrico Zimuel
Zend Framework 2 quick start
Zend Framework 2 quick start
Enrico Zimuel
How to scale PHP applications
How to scale PHP applications
Enrico Zimuel
Zend_Cache: how to improve the performance of PHP applications
Zend_Cache: how to improve the performance of PHP applications
Enrico Zimuel
Sviluppo di applicazioni sicure
Sviluppo di applicazioni sicure
Enrico Zimuel
Misure minime di sicurezza informatica
Misure minime di sicurezza informatica
Enrico Zimuel
PHP e crittografia
PHP e crittografia
Enrico Zimuel
Firma digitale
Firma digitale
Enrico Zimuel
Mais de Enrico Zimuel
(10)
Password (in)security
Password (in)security
Quick start on Zend Framework 2
Quick start on Zend Framework 2
A quick start on Zend Framework 2
A quick start on Zend Framework 2
Zend Framework 2 quick start
Zend Framework 2 quick start
How to scale PHP applications
How to scale PHP applications
Zend_Cache: how to improve the performance of PHP applications
Zend_Cache: how to improve the performance of PHP applications
Sviluppo di applicazioni sicure
Sviluppo di applicazioni sicure
Misure minime di sicurezza informatica
Misure minime di sicurezza informatica
PHP e crittografia
PHP e crittografia
Firma digitale
Firma digitale
PHP goes mobile
1.
Sviluppo di applicazioni
web mobile con Zend Framework Enrico Zimuel Senior PHP Engineer, Zend Technologies Zend Framework Core Team PHP goes mobile, 13 Aprile 2012 http://mobilephp.grusp.org/ © All rights reserved. Zend Technologies, Inc.
2.
Chi sono
● Software Engineer dal 1996 (1984?) ▶ Assembly, Basic, C/C++, Java, Perl, PHP ● PHP Engineer e Software Architect presso Zend Technologies dal 2008 ● Zend Framework Core Team dal 2011 ● Research Programmer presso l'Informatics Institute dell'Università di Amsterdam ● Co-autore del libro “PHP best practices” FAG edizioni (in corso di pubblicazione) © All rights reserved. Zend Technologies, Inc.
3.
Web mobile vs.
Native App © All rights reserved. Zend Technologies, Inc.
4.
Web mobile vs.
Native App Web mobile Native App Accesso al limitato totale dispositivo Velocità buona ottima Costi sviluppo bassi medio/alti Tecnologia open si a volte Ricavi 100% dipende Approvazione nessuna dipende Tempi di rilascio immediati 1-2 settimane Linguaggio di HTML e qualsiasi dipende programmazione altro (esempio PHP) © All rights reserved. Zend Technologies, Inc.
5.
Web mobile vs.
Native App (2) “People never cared about the Web vs. apps and devices . . . They want free stuff, entertainment, and services when they want them, and on the device they have in front of them” Fonte: Pew Internet Project (Marzo, 2012) © All rights reserved. Zend Technologies, Inc.
6.
Web mobile con
ZF © All rights reserved. Zend Technologies, Inc.
7.
Zend Framework ●
Framework PHP per lo sviluppo di applicazioni web ▶ > 10 milioni di download ▶ > 500 sviluppatori ▶ > 10 milioni hits su Google ● Open source, licenza basata su new BSD ● Versioni: 1.11.11 (PHP 5.2) e 2.0.0.beta3 (PHP 5.3+) ● Sito del progetto: http://framework.zend.com ● © Zend Technologies Ltd. © All rights reserved. Zend Technologies, Inc.
8.
Zend Technologies ●
Zend Technologies Ltd, the PHP Company ● Fondata nel 1999 da Andi Gutmans e Zeev Suraski, gli sviluppatori del PHP 3.0 ● Quartier generale nella Silicon Valley a Cupertino (USA) ● Uffici in: Francia, Germania, India, Irlanda, Israele, Italia ● © PHP Engine 2 (l'interprete del PHP) ● Sito: http://www.zend.com © All rights reserved. Zend Technologies, Inc.
9.
Componenti ZF per
il web mobile ● Zend_Http_UserAgent ▶ BrowsCap ▶ Tera-WURFL ▶ DeviceAtlas ● Context Switching ● Zend_Mobile ▶ Disponibile dalla versione 1.12 di ZF © All rights reserved. Zend Technologies, Inc.
10.
BrowsCap ●
Funzione get_browser() del PHP ● Configurazione: ▶ Download del file browscap.ini dal sito del progetto Browser Capabilities: http://browsers.garykeith.com/downloads ▶ Configurare php.ini con la direttiva: browscap=/path/to/browscap.ini © All rights reserved. Zend Technologies, Inc.
11.
Tera-WURFL ●
Tera-WURFL è una libreria in PHP e un database in MySQL/MSSQL/MongoDB di informazioni su device ● Download: http://dbapi.scientiamobile.com © All rights reserved. Zend Technologies, Inc.
12.
DeviceAtlas ●
Libreria disponibile per diversi linguaggi (PHP, Java, .NET, Python, Ruby) per il riconoscimento di mobile device ● Download: http://deviceatlas.com/resourcecentre/get+started/enterprise+api © All rights reserved. Zend Technologies, Inc.
13.
Zend_Http_UserAgent ●
Utilizzato per identificare il device dell'utente ● Utilizzabile in diversi punti di un'applicazione ZF ▶ Plugin (bootstrap) ▶ Controller ▶ View © All rights reserved. Zend Technologies, Inc.
14.
Zend_Http_UserAgent (2) ●
Plugin (bootstrap) ▶ $bootstrap = Zend_Controller_Front::getInstance()->getParam('bootstrap'); $userAgent = $bootstrap->getResource('useragent'); ● Controller ▶ $bootstrap = $this->getInvokeArg('bootstrap'); $userAgent = $bootstrap->getResource('useragent'); ● View ▶ $userAgent = $this->userAgent(); © All rights reserved. Zend Technologies, Inc.
15.
Alcuni metodi dell'UserAgent ●
getDevice() ● getBrowserType() ● getAllFeatures() ● hasFlashSupport() ● hasPdfSupport() ● hasPhoneNumber() ● httpsSupport() ● getMaxImageHeight() ● getMaxImageWidth() ● ... © All rights reserved. Zend Technologies, Inc.
16.
Context switching ●
ContextSwitching è un action helper che consente di definire risposte differenti a seconda del contesto (della richiesta) ● E' di solito utilizzato nei web services per differenziare la risposta (ad esempio Json o XML) ● Permette di definire contesti custom ▶ Aggiungere dei suffissi alle viste ▶ Modificare l'header HTTP ▶ Definire delle callback © All rights reserved. Zend Technologies, Inc.
17.
Esempio class Application_Plugin_Mobile extends
Zend_Controller_Plugin_Abstract { public function dispatchLoopStartup( Zend_Controller_Request_Abstract $request) { $contextSwitch = Zend_Controller_Action_HelperBroker::getStaticHelper('ContextSwitch'); $contextSwitch->clearContexts() ->setContext('iphone', array( 'suffix' => 'iphone', 'headers' => array( 'Content-Type' => 'text/html;Charset=UTF-8'), )) ->setContext('html', array( 'suffix' => 'html', 'headers' => array( 'Content-Type' => 'text/html;Charset=UTF-8'), )) ->setAutoDisableLayout(false) ->setDefaultcontext('html') ->initContext(); © All rights reserved. Zend Technologies, Inc.
18.
Esempio (2)
$bootstrap = Zend_Controller_Front::getInstance()->getParam('bootstrap'); $userAgent = $bootstrap->getResource('useragent'); switch($userAgent->getDevice()->getFeature('device')) { case 'iphone': $request->setParam('format','iphone'); break; default: $request->setParam('format','html'); } } } © All rights reserved. Zend Technologies, Inc.
19.
Esempio (3)
class IndexController extends Zend_Controller_Action { public function init() { $this->_helper->contextSwitch() ->addActionContext('index', 'iphone') ->initContext(); } … } index.phtml index.iphone.phtml View © All rights reserved. Zend Technologies, Inc.
20.
Zend_Mobile ●
Zend_Mobile_Push ▶ Invio di notifiche push verso specifici vendor ● APNS (iTouch/iPad/iPhone) ● C2DM (Google Android) ● MPNS (Windows Phone) © All rights reserved. Zend Technologies, Inc.
21.
Esempio $message = new
Zend_Mobile_Push_Message_Apns(); $message->setAlert('Zend Mobile Push Example'); $message->setBadge(1); $message->setSound('default'); $message->setId(time()); $message->setToken('ABCDEF0123456789'); $apns = new Zend_Mobile_Push_Apns(); $apns->setCertificate('/path/to/provisioning-certificate.pem'); // if you have a passphrase on your certificate: // $apns->setCertificatePassphrase('foobar'); ... © All rights reserved. Zend Technologies, Inc.
22.
Esempio (2) try {
$apns->connect(Zend_Mobile_Push_Apns::SERVER_SANDBOX_URI); } catch (Zend_Mobile_Push_Exception_ServerUnavailable $e) { // you can either attempt to reconnect here or try again later exit(1); } catch (Zend_Mobile_Push_Exception $e) { echo 'APNS Connection Error:' . $e->getMessage(); exit(1); } try { $apns->send($message); } catch (Zend_Mobile_Push_Exception_InvalidToken $e) { echo $e->getMessage(); } catch (Zend_Mobile_Push_Exception $e) { echo $e->getMessage(); } $apns->close(); © All rights reserved. Zend Technologies, Inc.
23.
Domande?
© All rights reserved. Zend Technologies, Inc.
24.
Grazie! Per maggiori informazioni: http://framework.zend.com/
© All rights reserved. Zend Technologies, Inc.
Baixar agora