SlideShare une entreprise Scribd logo
1  sur  15
Télécharger pour lire hors ligne
Web Service for Mobile
 6 jan 2013 @ Sripatum University

        Anuchit Chalothorn
       anoochit@gmail.com
About
●   Not a Teacher or Instructor
●   Not a Programmer or Developer
●   Senior Software Engineer at SIPA
●   Content writer not speaker
●   I use Linux :)
Rules
● You can leave every time.
● If you don't understand and you don't want to
  ask you can leave.
● If you want to learn by yourself and I'll give
  you a resources, you can leave.
● If you don't understand at all and everything
  as I said, you can leave and I'll give a
  resources, you can learning by yourself.
Quote
“If you cannot do great things, do small things
in a great way” - Napoleon Hill
What you have learn ?
● Web Service
● SOAP
● RESTful
  ○ Mobile App
  ○ REST Server
● How to interact between 2 devices
REST "No" official standard
But you should follow design guid line
● RESTful API Design
   ○ http://www.freshblurbs.
     com/blog/2011/06/19/pragmatic-restful-api-design.
     html
● Learn REST
   ○ http://www.restapitutorial.com
Small things
Make your web service using RESTful for your
WattPad-liked project, by the way answer this
questions :

● What, Who, Where, When
● How, How much and How many
REST with PHP Framework
● CakePHP is NOT REST Framework
● CakePHP is PHP Framework follow the
  MVC principle
● You can use nature of CakePHP implement
  REST server, it's too easy
  ○   CakePHP has own ORM (object-relational mapping)
  ○   Everything is Array
  ○   Extension and Plug in support
  ○   You can hook anyware
CakePHP Framework
The CakePHP framework provides a robust
base for your application. And since the
framework follows the principles of MVC, it
allows you to easily customize and extend most
aspects of your application.
Install CakePHP
● Download and extract CakePHP
● Change permission for tmp directory
● Config security and encryption
● Config database connection
● Define your model and relation according to
  your database schema
● Plan your URI and create new controller,
  model and view for each services
● Test with simple method like index()
JSON View
● Enable json and or xml extensions with
  Router::parseExtensions() in Router to
  handle multiple extensions eg. Router::
  parseExtensions('json'); for json extension.
● Add the RequestHandlerComponent to your
  controller’s list of components
JSON View
● Using Data View to set serialize key in
  special view variable. eg. $this->set
  ('_serialize', array('data'));
● If you are lazy you can force to use default
  view to render eg. $this->render(null,
  'ajax','/ajax/ajax');
● In data view in view file just show in json
  data eg. json_encode(compact('posts'));
Small thing for you
● CakePHP Cook Book
  ○ http://book.cakephp.org/2.0/en/index.html
You should know
After this class you should continue to study
● Cloud Service on any your platform
   ○ IaaS
   ○ PaaS
● Try to make your Mobile Application call
  these services
   ○ OAuth2
   ○ Social Network
Thank you

Contenu connexe

Tendances

Basic course for junior web developer
Basic course for junior web developerBasic course for junior web developer
Basic course for junior web developer
Tran Khoa
 

Tendances (19)

Web performance mercadolibre - ECI 2013
Web performance   mercadolibre - ECI 2013Web performance   mercadolibre - ECI 2013
Web performance mercadolibre - ECI 2013
 
Php workshop L02 php basics
Php workshop L02 php basicsPhp workshop L02 php basics
Php workshop L02 php basics
 
Introduction of javascript
Introduction of javascriptIntroduction of javascript
Introduction of javascript
 
Node js crash course session 5
Node js crash course   session 5Node js crash course   session 5
Node js crash course session 5
 
Introduction about-ajax-framework
Introduction about-ajax-frameworkIntroduction about-ajax-framework
Introduction about-ajax-framework
 
Read
ReadRead
Read
 
University of Delaware - Improving Web Protocols (early SPDY talk)
University of Delaware - Improving Web Protocols (early SPDY talk)University of Delaware - Improving Web Protocols (early SPDY talk)
University of Delaware - Improving Web Protocols (early SPDY talk)
 
At Your Service - Abusing the Service Workers Web API
At Your Service - Abusing the Service Workers Web APIAt Your Service - Abusing the Service Workers Web API
At Your Service - Abusing the Service Workers Web API
 
Mongodb
MongodbMongodb
Mongodb
 
Node js crash course session 6
Node js crash course   session 6Node js crash course   session 6
Node js crash course session 6
 
Javascript cross domain communication
Javascript cross domain communicationJavascript cross domain communication
Javascript cross domain communication
 
Ireland Moot 2013 Admin Workshop Afternoon Session
Ireland Moot 2013 Admin Workshop Afternoon SessionIreland Moot 2013 Admin Workshop Afternoon Session
Ireland Moot 2013 Admin Workshop Afternoon Session
 
Basic course for junior web developer
Basic course for junior web developerBasic course for junior web developer
Basic course for junior web developer
 
Getting Started with MongoDB
Getting Started with MongoDBGetting Started with MongoDB
Getting Started with MongoDB
 
Practical MySQL
Practical MySQLPractical MySQL
Practical MySQL
 
Jumpstart: Your Introduction to MongoDB
Jumpstart: Your Introduction to MongoDBJumpstart: Your Introduction to MongoDB
Jumpstart: Your Introduction to MongoDB
 
Joomla User Group Suffolk - July 2012 - Template Optimisation by Ruth Cheesle...
Joomla User Group Suffolk - July 2012 - Template Optimisation by Ruth Cheesle...Joomla User Group Suffolk - July 2012 - Template Optimisation by Ruth Cheesle...
Joomla User Group Suffolk - July 2012 - Template Optimisation by Ruth Cheesle...
 
Node js crash course session 3
Node js crash course   session 3Node js crash course   session 3
Node js crash course session 3
 
Cached and Confused: Web Cache Deception in the Wild
Cached and Confused: Web Cache Deception in the WildCached and Confused: Web Cache Deception in the Wild
Cached and Confused: Web Cache Deception in the Wild
 

En vedette

Open Source for Future Education
Open Source for Future EducationOpen Source for Future Education
Open Source for Future Education
Anuchit Chalothorn
 
Eei Ideas
Eei IdeasEei Ideas
Eei Ideas
salmond
 
Android App Development 00 : Course Overview
Android App Development 00 : Course OverviewAndroid App Development 00 : Course Overview
Android App Development 00 : Course Overview
Anuchit Chalothorn
 

En vedette (12)

Open Source for Future Education
Open Source for Future EducationOpen Source for Future Education
Open Source for Future Education
 
Eei Ideas
Eei IdeasEei Ideas
Eei Ideas
 
Seminar sured2
Seminar sured2Seminar sured2
Seminar sured2
 
Android App Development 00 : Course Overview
Android App Development 00 : Course OverviewAndroid App Development 00 : Course Overview
Android App Development 00 : Course Overview
 
Material Theme
Material ThemeMaterial Theme
Material Theme
 
00 Android Wear Setup Emulator
00 Android Wear Setup Emulator00 Android Wear Setup Emulator
00 Android Wear Setup Emulator
 
Redlinesoft Joomla Basic Workshop
Redlinesoft Joomla Basic WorkshopRedlinesoft Joomla Basic Workshop
Redlinesoft Joomla Basic Workshop
 
Online payments market guide 2014
Online payments market guide 2014Online payments market guide 2014
Online payments market guide 2014
 
The Evolution of Mobile Money: Retail, the next frontier
The Evolution of Mobile Money: Retail, the next frontierThe Evolution of Mobile Money: Retail, the next frontier
The Evolution of Mobile Money: Retail, the next frontier
 
Microservices are the Future! (...and always will be) - Josh Holtzman, PayPal...
Microservices are the Future! (...and always will be) - Josh Holtzman, PayPal...Microservices are the Future! (...and always will be) - Josh Holtzman, PayPal...
Microservices are the Future! (...and always will be) - Josh Holtzman, PayPal...
 
Web Services PHP Tutorial
Web Services PHP TutorialWeb Services PHP Tutorial
Web Services PHP Tutorial
 
PayPal Marketing Plan Presentation
PayPal Marketing Plan PresentationPayPal Marketing Plan Presentation
PayPal Marketing Plan Presentation
 

Similaire à Web Service and Mobile Integrated Day II

kranonit S06E01 Игорь Цинько: High load
kranonit S06E01 Игорь Цинько: High loadkranonit S06E01 Игорь Цинько: High load
kranonit S06E01 Игорь Цинько: High load
Krivoy Rog IT Community
 

Similaire à Web Service and Mobile Integrated Day II (20)

Starting a Drupal 8 Project? Let’s do a Technical Discovery - DrupalConAsia 2...
Starting a Drupal 8 Project? Let’s do a Technical Discovery - DrupalConAsia 2...Starting a Drupal 8 Project? Let’s do a Technical Discovery - DrupalConAsia 2...
Starting a Drupal 8 Project? Let’s do a Technical Discovery - DrupalConAsia 2...
 
Destination Documentation: How Not to Get Lost in Your Org
Destination Documentation: How Not to Get Lost in Your OrgDestination Documentation: How Not to Get Lost in Your Org
Destination Documentation: How Not to Get Lost in Your Org
 
kranonit S06E01 Игорь Цинько: High load
kranonit S06E01 Игорь Цинько: High loadkranonit S06E01 Игорь Цинько: High load
kranonit S06E01 Игорь Цинько: High load
 
What are the basic key points to focus on while learning Full-stack web devel...
What are the basic key points to focus on while learning Full-stack web devel...What are the basic key points to focus on while learning Full-stack web devel...
What are the basic key points to focus on while learning Full-stack web devel...
 
Spark Workflow Management
Spark Workflow ManagementSpark Workflow Management
Spark Workflow Management
 
The working architecture of NodeJS applications, Виктор Турский
The working architecture of NodeJS applications, Виктор ТурскийThe working architecture of NodeJS applications, Виктор Турский
The working architecture of NodeJS applications, Виктор Турский
 
The working architecture of node js applications open tech week javascript ...
The working architecture of node js applications   open tech week javascript ...The working architecture of node js applications   open tech week javascript ...
The working architecture of node js applications open tech week javascript ...
 
Intro to ember.js
Intro to ember.jsIntro to ember.js
Intro to ember.js
 
GraphQL Bangkok meetup 5.0
GraphQL Bangkok meetup 5.0GraphQL Bangkok meetup 5.0
GraphQL Bangkok meetup 5.0
 
Drupal 7 training
Drupal 7 trainingDrupal 7 training
Drupal 7 training
 
Introduction to Django
Introduction to DjangoIntroduction to Django
Introduction to Django
 
Dynatech presentation for TSI Career Day
Dynatech presentation for TSI Career DayDynatech presentation for TSI Career Day
Dynatech presentation for TSI Career Day
 
Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...
Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...
Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...
 
Introduction to django
Introduction to djangoIntroduction to django
Introduction to django
 
You can't make a (Denver) omelette without breaking eggs: Using OpenStack pol...
You can't make a (Denver) omelette without breaking eggs: Using OpenStack pol...You can't make a (Denver) omelette without breaking eggs: Using OpenStack pol...
You can't make a (Denver) omelette without breaking eggs: Using OpenStack pol...
 
OpenSearch.pdf
OpenSearch.pdfOpenSearch.pdf
OpenSearch.pdf
 
Flink Forward San Francisco 2018: Gregory Fee - "Bootstrapping State In Apach...
Flink Forward San Francisco 2018: Gregory Fee - "Bootstrapping State In Apach...Flink Forward San Francisco 2018: Gregory Fee - "Bootstrapping State In Apach...
Flink Forward San Francisco 2018: Gregory Fee - "Bootstrapping State In Apach...
 
Anatomy of a Spring Boot App with Clean Architecture - Spring I/O 2023
Anatomy of a Spring Boot App with Clean Architecture - Spring I/O 2023Anatomy of a Spring Boot App with Clean Architecture - Spring I/O 2023
Anatomy of a Spring Boot App with Clean Architecture - Spring I/O 2023
 
The current state of SAP Integration, SAPPHIRENOW 2018
The current state of SAP Integration, SAPPHIRENOW 2018The current state of SAP Integration, SAPPHIRENOW 2018
The current state of SAP Integration, SAPPHIRENOW 2018
 
Scaffolding the Generation of Machine Learning Models with SciRise
Scaffolding the Generation of Machine Learning Models with SciRiseScaffolding the Generation of Machine Learning Models with SciRise
Scaffolding the Generation of Machine Learning Models with SciRise
 

Plus de Anuchit Chalothorn

Plus de Anuchit Chalothorn (20)

Flutter Workshop 2021 @ ARU
Flutter Workshop 2021 @ ARUFlutter Workshop 2021 @ ARU
Flutter Workshop 2021 @ ARU
 
Flutter workshop @ bang saen 2020
Flutter workshop @ bang saen 2020Flutter workshop @ bang saen 2020
Flutter workshop @ bang saen 2020
 
13 web service integration
13 web service integration13 web service integration
13 web service integration
 
09 material design
09 material design09 material design
09 material design
 
07 intent
07 intent07 intent
07 intent
 
05 binding and action
05 binding and action05 binding and action
05 binding and action
 
04 layout design and basic widget
04 layout design and basic widget04 layout design and basic widget
04 layout design and basic widget
 
03 activity life cycle
03 activity life cycle03 activity life cycle
03 activity life cycle
 
02 create your first app
02 create your first app02 create your first app
02 create your first app
 
01 introduction
01 introduction 01 introduction
01 introduction
 
MongoDB Replication Cluster
MongoDB Replication ClusterMongoDB Replication Cluster
MongoDB Replication Cluster
 
MongoDB Shard Cluster
MongoDB Shard ClusterMongoDB Shard Cluster
MongoDB Shard Cluster
 
IT Automation with Chef
IT Automation with ChefIT Automation with Chef
IT Automation with Chef
 
IT Automation with Puppet Enterprise
IT Automation with Puppet EnterpriseIT Automation with Puppet Enterprise
IT Automation with Puppet Enterprise
 
Using PhoneGap Command Line
Using PhoneGap Command LineUsing PhoneGap Command Line
Using PhoneGap Command Line
 
Collaborative development with Git | Workshop
Collaborative development with Git | WorkshopCollaborative development with Git | Workshop
Collaborative development with Git | Workshop
 
OpenStack Cheat Sheet V2
OpenStack Cheat Sheet V2OpenStack Cheat Sheet V2
OpenStack Cheat Sheet V2
 
REST API with CakePHP
REST API with CakePHPREST API with CakePHP
REST API with CakePHP
 
Open Stack Cheat Sheet V1
Open Stack Cheat Sheet V1Open Stack Cheat Sheet V1
Open Stack Cheat Sheet V1
 
Btf2013 OpenShift Live Demo
Btf2013 OpenShift Live DemoBtf2013 OpenShift Live Demo
Btf2013 OpenShift Live Demo
 

Dernier

Dernier (20)

Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
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...
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
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?
 
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
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
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
 
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
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
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
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
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
 
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
 
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
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 

Web Service and Mobile Integrated Day II

  • 1. Web Service for Mobile 6 jan 2013 @ Sripatum University Anuchit Chalothorn anoochit@gmail.com
  • 2. About ● Not a Teacher or Instructor ● Not a Programmer or Developer ● Senior Software Engineer at SIPA ● Content writer not speaker ● I use Linux :)
  • 3. Rules ● You can leave every time. ● If you don't understand and you don't want to ask you can leave. ● If you want to learn by yourself and I'll give you a resources, you can leave. ● If you don't understand at all and everything as I said, you can leave and I'll give a resources, you can learning by yourself.
  • 4. Quote “If you cannot do great things, do small things in a great way” - Napoleon Hill
  • 5. What you have learn ? ● Web Service ● SOAP ● RESTful ○ Mobile App ○ REST Server ● How to interact between 2 devices
  • 6. REST "No" official standard But you should follow design guid line ● RESTful API Design ○ http://www.freshblurbs. com/blog/2011/06/19/pragmatic-restful-api-design. html ● Learn REST ○ http://www.restapitutorial.com
  • 7. Small things Make your web service using RESTful for your WattPad-liked project, by the way answer this questions : ● What, Who, Where, When ● How, How much and How many
  • 8. REST with PHP Framework ● CakePHP is NOT REST Framework ● CakePHP is PHP Framework follow the MVC principle ● You can use nature of CakePHP implement REST server, it's too easy ○ CakePHP has own ORM (object-relational mapping) ○ Everything is Array ○ Extension and Plug in support ○ You can hook anyware
  • 9. CakePHP Framework The CakePHP framework provides a robust base for your application. And since the framework follows the principles of MVC, it allows you to easily customize and extend most aspects of your application.
  • 10. Install CakePHP ● Download and extract CakePHP ● Change permission for tmp directory ● Config security and encryption ● Config database connection ● Define your model and relation according to your database schema ● Plan your URI and create new controller, model and view for each services ● Test with simple method like index()
  • 11. JSON View ● Enable json and or xml extensions with Router::parseExtensions() in Router to handle multiple extensions eg. Router:: parseExtensions('json'); for json extension. ● Add the RequestHandlerComponent to your controller’s list of components
  • 12. JSON View ● Using Data View to set serialize key in special view variable. eg. $this->set ('_serialize', array('data')); ● If you are lazy you can force to use default view to render eg. $this->render(null, 'ajax','/ajax/ajax'); ● In data view in view file just show in json data eg. json_encode(compact('posts'));
  • 13. Small thing for you ● CakePHP Cook Book ○ http://book.cakephp.org/2.0/en/index.html
  • 14. You should know After this class you should continue to study ● Cloud Service on any your platform ○ IaaS ○ PaaS ● Try to make your Mobile Application call these services ○ OAuth2 ○ Social Network