Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

JSON vs XML

//JSON Example
{"employees":[
  { "firstName":"John", "lastName":"Doe" },
  { "firstName":"Anna", "lastName":"Smith" },
  { "firstName":"Peter", "lastName":"Jones" }
]}

//XML Example
<employees>
  <employee>
    <firstName>John</firstName> <lastName>Doe</lastName>
  </employee>
  <employee>
    <firstName>Anna</firstName> <lastName>Smith</lastName>
  </employee>
  <employee>
    <firstName>Peter</firstName> <lastName>Jones</lastName>
  </employee>
</employees>
Comment

xml vs json

These are 2 common formats that we use when exchanging data across the web: 

-- eXtensible Markup Language (XML) has been in use for a very long time and is 
best suited for exchanging document-style data
-- when programs just want to exchange dictionaries, lists, or other internal 
information with each other, they use JavaScript Object Notation (JSON)
Comment

PREVIOUS NEXT
Code Example
Javascript :: javascript how to remove first element of array 
Javascript :: change array index position in javascript by up and down click 
Javascript :: jquery ajax true false as boolean value 
Javascript :: dull a background image in react native 
Javascript :: convert data image url into an image file 
Javascript :: arrow function = breakdown steps 
Javascript :: set time in javascript 
Javascript :: how to send js array from ajax 
Javascript :: javascript map function 
Javascript :: render image in vue 
Javascript :: add parameter at the end of url from jquery with refreshing 
Javascript :: material ui icons next js 
Javascript :: d3 paning 
Javascript :: like in mongodb 
Javascript :: monaco editor get value 
Javascript :: Search array of objects for existing value 
Javascript :: react function 
Javascript :: angular infinite scroll 
Javascript :: classlist remove multiple classes 
Javascript :: node save wav base64 
Javascript :: react native expo flatlist 
Javascript :: javascript formate date 
Javascript :: crypto in node js 
Javascript :: jQuery DataTables Checkboxes 
Javascript :: remove an last item of array in javascript 
Javascript :: discord.js if no arguments 
Javascript :: js byte size 
Javascript :: input type number max value validation 
Javascript :: async function in variable 
Javascript :: how set type of string value to number in js 
ADD CONTENT
Topic
Content
Source link
Name
4+5 =