SlideShare a Scribd company logo
JSON for JavaScript
Ahmed Elbassel
Email: elbassel.n13@gmail.com
Skype: ahmed_elbassel
JSON
- What is JSON? Why JSON?
- JSON Syntax
- JSON examples
- Accessing JSON
- JSON From/To String
- JSON online tools
- References
What is JSON? Why JSON?
- What is JSON?
- JSON stands for JavaScript Object Notation
- JSON is a lightweight data-interchange format
- JSON is "self-describing" and easy to understand
- JSON is language independent
- Why JSON?
- Since the JSON format is text only, it can easily be sent to and from a server, and used as a
data format by any programming language.
JSON Syntax
- Data is in name/value pairs
- Data is separated by commas
- Curly braces hold objects
- Square brackets hold arrays
- Name: can be single word, dashed words, underscore words, or
dotted words.
- {"age": 44,"age_i":55, "age.p":100};
JSON Syntax
Accessing JSON
- Name is single word:
- User.name
- Name is any type, single, dashed, underscored, or dotted.
- user[‘name’] or user[“name”]
JSON from/to String
- String to JSON
- JS code:
- JSON to String:
- JS code:
JSON online tools
- Formatting tools:
- http://www.jsoneditoronline.org/
- http://json.parser.online.fr/
- http://jsonviewer.stack.hu/
- https://jsonformatter.curiousconcept.com/
- http://codebeautify.org/jsonviewer
- http://www.freeformatter.com/json-formatter.html
References
http://www.w3schools.com/js/js_json_intro.asp

More Related Content

Viewers also liked

Voz Pasiva
Voz PasivaVoz Pasiva
JSON-RPC Proxy Generation with PHP 5
JSON-RPC Proxy Generation with PHP 5JSON-RPC Proxy Generation with PHP 5
JSON-RPC Proxy Generation with PHP 5
Stephan Schmidt
 
RESTful JSON web databases
RESTful JSON web databasesRESTful JSON web databases
RESTful JSON web databases
kriszyp
 
Mars
MarsMars
Mars
raja1233
 
Seattle SeaHawks
Seattle SeaHawksSeattle SeaHawks
Seattle SeaHawks
1apinedo
 
Advanced Json
Advanced JsonAdvanced Json
Advanced Json
guestfd7d7c
 
Мероприятия как инструмент работы с молодыми специалистами и продвижения брен...
Мероприятия как инструмент работы с молодыми специалистами и продвижения брен...Мероприятия как инструмент работы с молодыми специалистами и продвижения брен...
Мероприятия как инструмент работы с молодыми специалистами и продвижения брен...
FutureToday
 
Uncle Ben's Recipe Video Contest Flyer
Uncle Ben's Recipe Video Contest FlyerUncle Ben's Recipe Video Contest Flyer
Uncle Ben's Recipe Video Contest Flyer
aeiser
 
CouchDB Day NYC 2017: JSON Documents
CouchDB Day NYC 2017: JSON DocumentsCouchDB Day NYC 2017: JSON Documents
CouchDB Day NYC 2017: JSON Documents
IBM Cloud Data Services
 
02 Node introduction
02 Node introduction02 Node introduction
02 Node introduction
Ahmed Elbassel
 

Viewers also liked (10)

Voz Pasiva
Voz PasivaVoz Pasiva
Voz Pasiva
 
JSON-RPC Proxy Generation with PHP 5
JSON-RPC Proxy Generation with PHP 5JSON-RPC Proxy Generation with PHP 5
JSON-RPC Proxy Generation with PHP 5
 
RESTful JSON web databases
RESTful JSON web databasesRESTful JSON web databases
RESTful JSON web databases
 
Mars
MarsMars
Mars
 
Seattle SeaHawks
Seattle SeaHawksSeattle SeaHawks
Seattle SeaHawks
 
Advanced Json
Advanced JsonAdvanced Json
Advanced Json
 
Мероприятия как инструмент работы с молодыми специалистами и продвижения брен...
Мероприятия как инструмент работы с молодыми специалистами и продвижения брен...Мероприятия как инструмент работы с молодыми специалистами и продвижения брен...
Мероприятия как инструмент работы с молодыми специалистами и продвижения брен...
 
Uncle Ben's Recipe Video Contest Flyer
Uncle Ben's Recipe Video Contest FlyerUncle Ben's Recipe Video Contest Flyer
Uncle Ben's Recipe Video Contest Flyer
 
CouchDB Day NYC 2017: JSON Documents
CouchDB Day NYC 2017: JSON DocumentsCouchDB Day NYC 2017: JSON Documents
CouchDB Day NYC 2017: JSON Documents
 
02 Node introduction
02 Node introduction02 Node introduction
02 Node introduction
 

Similar to 03 json for java script

JSON - (English)
JSON - (English)JSON - (English)
JSON - (English)
Senior Dev
 
JSON.pptx
JSON.pptxJSON.pptx
JSON.pptx
MaheshHirulkar1
 
What is JSON? Why use JSON? JSON Types? JSON Helpful Tools?
What is JSON? Why use JSON? JSON Types? JSON Helpful Tools?What is JSON? Why use JSON? JSON Types? JSON Helpful Tools?
What is JSON? Why use JSON? JSON Types? JSON Helpful Tools?
codeandyou forums
 
Json
JsonJson
Json
soumya
 
JSON
JSONJSON
Java Script Object Notation (JSON)
Java Script Object Notation (JSON)Java Script Object Notation (JSON)
Java Script Object Notation (JSON)
Adnan Sohail
 
java script json
java script jsonjava script json
java script json
chauhankapil
 
Json
JsonJson
Hands on JSON
Hands on JSONHands on JSON
Hands on JSON
Octavian Nadolu
 
JSON - JavaScript Object Notation
JSON - JavaScript Object NotationJSON - JavaScript Object Notation
JSON - JavaScript Object Notation
Sothearin Ren
 
JSON PRETTIFY.pdf
JSON PRETTIFY.pdfJSON PRETTIFY.pdf
JSON PRETTIFY.pdf
json beautifier
 
JSON beautifier (1).pdf
JSON beautifier (1).pdfJSON beautifier (1).pdf
JSON beautifier (1).pdf
json beautifier
 
JSON: The Basics
JSON: The BasicsJSON: The Basics
JSON: The Basics
Jeff Fox
 
Writing Domain Specific Languages with JSON Schema
Writing Domain Specific Languages with JSON SchemaWriting Domain Specific Languages with JSON Schema
Writing Domain Specific Languages with JSON Schema
Yos Riady
 
Dealing with JSON files in python with illustrations
Dealing with JSON files in python with illustrationsDealing with JSON files in python with illustrations
Dealing with JSON files in python with illustrations
Kiran Kumaraswamy
 
JSON - Quick Overview
JSON - Quick OverviewJSON - Quick Overview
JSON - Quick Overview
Signure Technologies
 
Json
JsonJson
An introduction to json
An introduction to jsonAn introduction to json
An introduction to json
Naveenkumar5964
 
Intro to JSON
Intro to JSONIntro to JSON
Intro to JSON
Mark Daniel Dacer
 
All about XML, JSON and related topics..
All about XML, JSON and related topics..All about XML, JSON and related topics..
All about XML, JSON and related topics..
tinumanueltmt
 

Similar to 03 json for java script (20)

JSON - (English)
JSON - (English)JSON - (English)
JSON - (English)
 
JSON.pptx
JSON.pptxJSON.pptx
JSON.pptx
 
What is JSON? Why use JSON? JSON Types? JSON Helpful Tools?
What is JSON? Why use JSON? JSON Types? JSON Helpful Tools?What is JSON? Why use JSON? JSON Types? JSON Helpful Tools?
What is JSON? Why use JSON? JSON Types? JSON Helpful Tools?
 
Json
JsonJson
Json
 
JSON
JSONJSON
JSON
 
Java Script Object Notation (JSON)
Java Script Object Notation (JSON)Java Script Object Notation (JSON)
Java Script Object Notation (JSON)
 
java script json
java script jsonjava script json
java script json
 
Json
JsonJson
Json
 
Hands on JSON
Hands on JSONHands on JSON
Hands on JSON
 
JSON - JavaScript Object Notation
JSON - JavaScript Object NotationJSON - JavaScript Object Notation
JSON - JavaScript Object Notation
 
JSON PRETTIFY.pdf
JSON PRETTIFY.pdfJSON PRETTIFY.pdf
JSON PRETTIFY.pdf
 
JSON beautifier (1).pdf
JSON beautifier (1).pdfJSON beautifier (1).pdf
JSON beautifier (1).pdf
 
JSON: The Basics
JSON: The BasicsJSON: The Basics
JSON: The Basics
 
Writing Domain Specific Languages with JSON Schema
Writing Domain Specific Languages with JSON SchemaWriting Domain Specific Languages with JSON Schema
Writing Domain Specific Languages with JSON Schema
 
Dealing with JSON files in python with illustrations
Dealing with JSON files in python with illustrationsDealing with JSON files in python with illustrations
Dealing with JSON files in python with illustrations
 
JSON - Quick Overview
JSON - Quick OverviewJSON - Quick Overview
JSON - Quick Overview
 
Json
JsonJson
Json
 
An introduction to json
An introduction to jsonAn introduction to json
An introduction to json
 
Intro to JSON
Intro to JSONIntro to JSON
Intro to JSON
 
All about XML, JSON and related topics..
All about XML, JSON and related topics..All about XML, JSON and related topics..
All about XML, JSON and related topics..
 

More from Ahmed Elbassel

13 mongoose
13 mongoose13 mongoose
13 mongoose
Ahmed Elbassel
 
12 mongo db_and_nodejs
12 mongo db_and_nodejs12 mongo db_and_nodejs
12 mongo db_and_nodejs
Ahmed Elbassel
 
11 schema design & crud
11 schema design & crud11 schema design & crud
11 schema design & crud
Ahmed Elbassel
 
10 mongo db
10 mongo db10 mongo db
10 mongo db
Ahmed Elbassel
 
09 express, moooore
09 express, moooore09 express, moooore
09 express, moooore
Ahmed Elbassel
 
08 express introduction
08 express introduction08 express introduction
08 express introduction
Ahmed Elbassel
 
07 restful webservices design
07 restful webservices design07 restful webservices design
07 restful webservices design
Ahmed Elbassel
 
06 start node coding
06 start node coding06 start node coding
06 start node coding
Ahmed Elbassel
 
Airbnb Java Script style guide
Airbnb Java Script style guideAirbnb Java Script style guide
Airbnb Java Script style guide
Ahmed Elbassel
 
Story of java
Story of javaStory of java
Story of java
Ahmed Elbassel
 

More from Ahmed Elbassel (10)

13 mongoose
13 mongoose13 mongoose
13 mongoose
 
12 mongo db_and_nodejs
12 mongo db_and_nodejs12 mongo db_and_nodejs
12 mongo db_and_nodejs
 
11 schema design & crud
11 schema design & crud11 schema design & crud
11 schema design & crud
 
10 mongo db
10 mongo db10 mongo db
10 mongo db
 
09 express, moooore
09 express, moooore09 express, moooore
09 express, moooore
 
08 express introduction
08 express introduction08 express introduction
08 express introduction
 
07 restful webservices design
07 restful webservices design07 restful webservices design
07 restful webservices design
 
06 start node coding
06 start node coding06 start node coding
06 start node coding
 
Airbnb Java Script style guide
Airbnb Java Script style guideAirbnb Java Script style guide
Airbnb Java Script style guide
 
Story of java
Story of javaStory of java
Story of java
 

Recently uploaded

Ericsson LTE Throughput Troubleshooting Techniques.ppt
Ericsson LTE Throughput Troubleshooting Techniques.pptEricsson LTE Throughput Troubleshooting Techniques.ppt
Ericsson LTE Throughput Troubleshooting Techniques.ppt
wafawafa52
 
AI + Data Community Tour - Build the Next Generation of Apps with the Einstei...
AI + Data Community Tour - Build the Next Generation of Apps with the Einstei...AI + Data Community Tour - Build the Next Generation of Apps with the Einstei...
AI + Data Community Tour - Build the Next Generation of Apps with the Einstei...
Paris Salesforce Developer Group
 
Accident detection system project report.pdf
Accident detection system project report.pdfAccident detection system project report.pdf
Accident detection system project report.pdf
Kamal Acharya
 
原版制作(Humboldt毕业证书)柏林大学毕业证学位证一模一样
原版制作(Humboldt毕业证书)柏林大学毕业证学位证一模一样原版制作(Humboldt毕业证书)柏林大学毕业证学位证一模一样
原版制作(Humboldt毕业证书)柏林大学毕业证学位证一模一样
ydzowc
 
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
upoux
 
一比一原版(uoft毕业证书)加拿大多伦多大学毕业证如何办理
一比一原版(uoft毕业证书)加拿大多伦多大学毕业证如何办理一比一原版(uoft毕业证书)加拿大多伦多大学毕业证如何办理
一比一原版(uoft毕业证书)加拿大多伦多大学毕业证如何办理
sydezfe
 
Call For Paper -3rd International Conference on Artificial Intelligence Advan...
Call For Paper -3rd International Conference on Artificial Intelligence Advan...Call For Paper -3rd International Conference on Artificial Intelligence Advan...
Call For Paper -3rd International Conference on Artificial Intelligence Advan...
ijseajournal
 
Determination of Equivalent Circuit parameters and performance characteristic...
Determination of Equivalent Circuit parameters and performance characteristic...Determination of Equivalent Circuit parameters and performance characteristic...
Determination of Equivalent Circuit parameters and performance characteristic...
pvpriya2
 
Tools & Techniques for Commissioning and Maintaining PV Systems W-Animations ...
Tools & Techniques for Commissioning and Maintaining PV Systems W-Animations ...Tools & Techniques for Commissioning and Maintaining PV Systems W-Animations ...
Tools & Techniques for Commissioning and Maintaining PV Systems W-Animations ...
Transcat
 
Levelised Cost of Hydrogen (LCOH) Calculator Manual
Levelised Cost of Hydrogen  (LCOH) Calculator ManualLevelised Cost of Hydrogen  (LCOH) Calculator Manual
Levelised Cost of Hydrogen (LCOH) Calculator Manual
Massimo Talia
 
FULL STACK PROGRAMMING - Both Front End and Back End
FULL STACK PROGRAMMING - Both Front End and Back EndFULL STACK PROGRAMMING - Both Front End and Back End
FULL STACK PROGRAMMING - Both Front End and Back End
PreethaV16
 
Assistant Engineer (Chemical) Interview Questions.pdf
Assistant Engineer (Chemical) Interview Questions.pdfAssistant Engineer (Chemical) Interview Questions.pdf
Assistant Engineer (Chemical) Interview Questions.pdf
Seetal Daas
 
Presentation on Food Delivery Systems
Presentation on Food Delivery SystemsPresentation on Food Delivery Systems
Presentation on Food Delivery Systems
Abdullah Al Noman
 
Call Girls Chennai +91-8824825030 Vip Call Girls Chennai
Call Girls Chennai +91-8824825030 Vip Call Girls ChennaiCall Girls Chennai +91-8824825030 Vip Call Girls Chennai
Call Girls Chennai +91-8824825030 Vip Call Girls Chennai
paraasingh12 #V08
 
SCALING OF MOS CIRCUITS m .pptx
SCALING OF MOS CIRCUITS m                 .pptxSCALING OF MOS CIRCUITS m                 .pptx
SCALING OF MOS CIRCUITS m .pptx
harshapolam10
 
openshift technical overview - Flow of openshift containerisatoin
openshift technical overview - Flow of openshift containerisatoinopenshift technical overview - Flow of openshift containerisatoin
openshift technical overview - Flow of openshift containerisatoin
snaprevwdev
 
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
DharmaBanothu
 
EV BMS WITH CHARGE MONITOR AND FIRE DETECTION.pptx
EV BMS WITH CHARGE MONITOR AND FIRE DETECTION.pptxEV BMS WITH CHARGE MONITOR AND FIRE DETECTION.pptx
EV BMS WITH CHARGE MONITOR AND FIRE DETECTION.pptx
nikshimanasa
 
Introduction to Computer Networks & OSI MODEL.ppt
Introduction to Computer Networks & OSI MODEL.pptIntroduction to Computer Networks & OSI MODEL.ppt
Introduction to Computer Networks & OSI MODEL.ppt
Dwarkadas J Sanghvi College of Engineering
 
一比一原版(USF毕业证)旧金山大学毕业证如何办理
一比一原版(USF毕业证)旧金山大学毕业证如何办理一比一原版(USF毕业证)旧金山大学毕业证如何办理
一比一原版(USF毕业证)旧金山大学毕业证如何办理
uqyfuc
 

Recently uploaded (20)

Ericsson LTE Throughput Troubleshooting Techniques.ppt
Ericsson LTE Throughput Troubleshooting Techniques.pptEricsson LTE Throughput Troubleshooting Techniques.ppt
Ericsson LTE Throughput Troubleshooting Techniques.ppt
 
AI + Data Community Tour - Build the Next Generation of Apps with the Einstei...
AI + Data Community Tour - Build the Next Generation of Apps with the Einstei...AI + Data Community Tour - Build the Next Generation of Apps with the Einstei...
AI + Data Community Tour - Build the Next Generation of Apps with the Einstei...
 
Accident detection system project report.pdf
Accident detection system project report.pdfAccident detection system project report.pdf
Accident detection system project report.pdf
 
原版制作(Humboldt毕业证书)柏林大学毕业证学位证一模一样
原版制作(Humboldt毕业证书)柏林大学毕业证学位证一模一样原版制作(Humboldt毕业证书)柏林大学毕业证学位证一模一样
原版制作(Humboldt毕业证书)柏林大学毕业证学位证一模一样
 
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
 
一比一原版(uoft毕业证书)加拿大多伦多大学毕业证如何办理
一比一原版(uoft毕业证书)加拿大多伦多大学毕业证如何办理一比一原版(uoft毕业证书)加拿大多伦多大学毕业证如何办理
一比一原版(uoft毕业证书)加拿大多伦多大学毕业证如何办理
 
Call For Paper -3rd International Conference on Artificial Intelligence Advan...
Call For Paper -3rd International Conference on Artificial Intelligence Advan...Call For Paper -3rd International Conference on Artificial Intelligence Advan...
Call For Paper -3rd International Conference on Artificial Intelligence Advan...
 
Determination of Equivalent Circuit parameters and performance characteristic...
Determination of Equivalent Circuit parameters and performance characteristic...Determination of Equivalent Circuit parameters and performance characteristic...
Determination of Equivalent Circuit parameters and performance characteristic...
 
Tools & Techniques for Commissioning and Maintaining PV Systems W-Animations ...
Tools & Techniques for Commissioning and Maintaining PV Systems W-Animations ...Tools & Techniques for Commissioning and Maintaining PV Systems W-Animations ...
Tools & Techniques for Commissioning and Maintaining PV Systems W-Animations ...
 
Levelised Cost of Hydrogen (LCOH) Calculator Manual
Levelised Cost of Hydrogen  (LCOH) Calculator ManualLevelised Cost of Hydrogen  (LCOH) Calculator Manual
Levelised Cost of Hydrogen (LCOH) Calculator Manual
 
FULL STACK PROGRAMMING - Both Front End and Back End
FULL STACK PROGRAMMING - Both Front End and Back EndFULL STACK PROGRAMMING - Both Front End and Back End
FULL STACK PROGRAMMING - Both Front End and Back End
 
Assistant Engineer (Chemical) Interview Questions.pdf
Assistant Engineer (Chemical) Interview Questions.pdfAssistant Engineer (Chemical) Interview Questions.pdf
Assistant Engineer (Chemical) Interview Questions.pdf
 
Presentation on Food Delivery Systems
Presentation on Food Delivery SystemsPresentation on Food Delivery Systems
Presentation on Food Delivery Systems
 
Call Girls Chennai +91-8824825030 Vip Call Girls Chennai
Call Girls Chennai +91-8824825030 Vip Call Girls ChennaiCall Girls Chennai +91-8824825030 Vip Call Girls Chennai
Call Girls Chennai +91-8824825030 Vip Call Girls Chennai
 
SCALING OF MOS CIRCUITS m .pptx
SCALING OF MOS CIRCUITS m                 .pptxSCALING OF MOS CIRCUITS m                 .pptx
SCALING OF MOS CIRCUITS m .pptx
 
openshift technical overview - Flow of openshift containerisatoin
openshift technical overview - Flow of openshift containerisatoinopenshift technical overview - Flow of openshift containerisatoin
openshift technical overview - Flow of openshift containerisatoin
 
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
 
EV BMS WITH CHARGE MONITOR AND FIRE DETECTION.pptx
EV BMS WITH CHARGE MONITOR AND FIRE DETECTION.pptxEV BMS WITH CHARGE MONITOR AND FIRE DETECTION.pptx
EV BMS WITH CHARGE MONITOR AND FIRE DETECTION.pptx
 
Introduction to Computer Networks & OSI MODEL.ppt
Introduction to Computer Networks & OSI MODEL.pptIntroduction to Computer Networks & OSI MODEL.ppt
Introduction to Computer Networks & OSI MODEL.ppt
 
一比一原版(USF毕业证)旧金山大学毕业证如何办理
一比一原版(USF毕业证)旧金山大学毕业证如何办理一比一原版(USF毕业证)旧金山大学毕业证如何办理
一比一原版(USF毕业证)旧金山大学毕业证如何办理
 

03 json for java script

  • 1. JSON for JavaScript Ahmed Elbassel Email: elbassel.n13@gmail.com Skype: ahmed_elbassel
  • 2. JSON - What is JSON? Why JSON? - JSON Syntax - JSON examples - Accessing JSON - JSON From/To String - JSON online tools - References
  • 3. What is JSON? Why JSON? - What is JSON? - JSON stands for JavaScript Object Notation - JSON is a lightweight data-interchange format - JSON is "self-describing" and easy to understand - JSON is language independent - Why JSON? - Since the JSON format is text only, it can easily be sent to and from a server, and used as a data format by any programming language.
  • 4. JSON Syntax - Data is in name/value pairs - Data is separated by commas - Curly braces hold objects - Square brackets hold arrays - Name: can be single word, dashed words, underscore words, or dotted words. - {"age": 44,"age_i":55, "age.p":100};
  • 6. Accessing JSON - Name is single word: - User.name - Name is any type, single, dashed, underscored, or dotted. - user[‘name’] or user[“name”]
  • 7. JSON from/to String - String to JSON - JS code: - JSON to String: - JS code:
  • 8. JSON online tools - Formatting tools: - http://www.jsoneditoronline.org/ - http://json.parser.online.fr/ - http://jsonviewer.stack.hu/ - https://jsonformatter.curiousconcept.com/ - http://codebeautify.org/jsonviewer - http://www.freeformatter.com/json-formatter.html