Essentials of Javascript - Cultural View
Essentials of Javascript - Cultural View Essentials of Javascript - Cultural View
JavascriptMVC 97 "other.event subscribe": function(ev, publisherData){ } }); View // TODO: do something JavaScriptMVC uses EJS templates to render HTML data in controllers and inject them into the DOM. The syntax was inspired by ERuby and is similar to PHP or other server-side template engines. For example file "test.ejs" ( data = [ "Hello", "World" ] ):
JSON 98 JSON Filename extension .json Internet media type application/json Type of format Data interchange Extended from JavaScript Standard(s) RFC 4627 Website http://json.org JSON (an acronym for JavaScript Object Notation) is a lightweight text-based open standard designed for human-readable data interchange. It is derived from the JavaScript programming language for representing simple data structures and associative arrays, called objects. Despite its relationship to JavaScript, it is language-independent, with parsers available for virtually every programming language. The JSON format was originally specified by Douglas Crockford, and is described in RFC 4627. The official Internet media type for JSON is application/json. The JSON filename extension is .json. The JSON format is often used for serializing and transmitting structured data over a network connection. It is primarily used to transmit data between a server and web application, serving as an alternative to XML. History Douglas Crockford was the first to specify and popularize the JSON format. [1] JSON was used at State Software, a company co-founded by Crockford, starting around 2001. The JSON.org website was launched in 2002. In December 2005, Yahoo! began offering some of its web services in JSON. [2] Google started offering JSON feeds for its GData web protocol in December 2006. [3] Although JSON was based on a subset of the JavaScript programming language (specifically, Standard ECMA-262 3rd Edition—December 1999 [4] ) and is commonly used with that language, it is considered to be a language-independent data format. Code for parsing and generating JSON data is readily available for a large variety of programming languages. json.org [5] provides a comprehensive listing of existing JSON libraries, organized by language. Data types, syntax and example JSON's basic types are: • Number (integer or real) • String (double-quoted Unicode with backslash escaping) • Boolean (true or false) • Array (an ordered sequence of values, comma-separated and enclosed in square brackets) • Object (a collection of key:value pairs, comma-separated and enclosed in curly braces) • null The following example shows the JSON representation of an object that describes a person. The object has string fields for first name and last name, contains an object representing the person's address, and contains a list (an array) of phone number objects.
- Page 49 and 50: JavaScript engine 46 JavaScript eng
- Page 51 and 52: Ajax (programming) 48 Ajax (program
- Page 53 and 54: Ajax (programming) 50 • Ajax-powe
- Page 55 and 56: ?: 52 ?: In computer programming, ?
- Page 57 and 58: ?: 54 Furthermore, the ternary oper
- Page 59 and 60: ?: 56 ?: in style guidelines Some c
- Page 61 and 62: Appcelerator Titanium 58 See also
- Page 63 and 64: Bookmarklet 60 Bookmarklet A bookma
- Page 65 and 66: Bookmarklet 62 References [1] Domai
- Page 67 and 68: Client-side JavaScript 64 implement
- Page 69 and 70: Client-side JavaScript 66 Reference
- Page 71 and 72: dhtmlx [1] Comparison of JavaScript
- Page 73 and 74: ility / ion Comparison of JavaScrip
- Page 75 and 76: Comparison of JavaScript frameworks
- Page 77 and 78: Comparison of JavaScript frameworks
- Page 79 and 80: Comparison of JavaScript-based sour
- Page 81 and 82: Comparison of JavaScript-based sour
- Page 83 and 84: Douglas Crockford 80 Douglas Crockf
- Page 85 and 86: DWR (Java) 82 DWR (Java) Developer(
- Page 87 and 88: EMVC 84 EMVC Developer(s) Ed Hertzo
- Page 89 and 90: Brendan Eich 86 References [1] Stev
- Page 91 and 92: JSDoc 88 JSDoc JSDoc is a syntax fo
- Page 93 and 94: JSDoc 90 History The earliest examp
- Page 95 and 96: JSSP 92 JSSP JSSP, or JavaScript Se
- Page 97 and 98: JScript 94 JScript is sometimes ref
- Page 99: JScript 96 [9] http://msdn2.microso
- Page 103 and 104: JSON 100 Using JSON in Ajax The fol
- Page 105 and 106: JSON 102 /> state='NY' postalCode='
- Page 107 and 108: JSON 104 parseResponse({"Name": "Ch
- Page 109 and 110: JSON 106 [21] Ben-Kiki, Oren; Evans
- Page 111 and 112: JsonML 108 ["person", {"created":"
- Page 113 and 114: Lightbox (JavaScript) 110 Lightbox
- Page 115 and 116: Lively Kernel 112 Lively Kernel Liv
- Page 117 and 118: Lively Kernel 114 The Lively Wiki T
- Page 119 and 120: Lively Kernel 116 }); } External li
- Page 121 and 122: Minification (programming) 118 Mini
- Page 123 and 124: Objective-J 120 Objective-J Paradig
- Page 125 and 126: John Resig 122 John Resig John Resi
- Page 127 and 128: Reverse Ajax 124 External links •
- Page 129 and 130: Seed (programming) 126 Seed (progra
- Page 131 and 132: Seed (programming) 128 See also •
- Page 133 and 134: Comparison of Server-side JavaScrip
- Page 135 and 136: Comparison of Server-side JavaScrip
- Page 137 and 138: Comparison of Server-side JavaScrip
- Page 139 and 140: SproutCore 136 • Tasks. Tasks man
- Page 141 and 142: Unobtrusive JavaScript 138 }); Beca
- Page 143 and 144: Venkman 140 External links • Venk
- Page 145 and 146: XMLHttpRequest 142 Microsoft added
- Page 147 and 148: XMLHttpRequest 144 The send method
- Page 149 and 150: XMLHttpRequest 146 [21] "Specificat
JSON 98<br />
JSON<br />
Filename extension .json<br />
Internet media<br />
type<br />
application/json<br />
Type <strong>of</strong> format Data<br />
interchange<br />
Extended from JavaScript<br />
Standard(s) RFC 4627<br />
Website http://json.org<br />
JSON (an acronym for JavaScript Object Notation) is a lightweight text-based open standard designed for<br />
human-readable data interchange. It is derived from the JavaScript programming language for representing simple<br />
data structures and associative arrays, called objects. Despite its relationship to JavaScript, it is<br />
language-independent, with parsers available for virtually every programming language.<br />
The JSON format was originally specified by Douglas Crockford, and is described in RFC 4627. The <strong>of</strong>ficial<br />
Internet media type for JSON is application/json. The JSON filename extension is .json.<br />
The JSON format is <strong>of</strong>ten used for serializing and transmitting structured data over a network connection. It is<br />
primarily used to transmit data between a server and web application, serving as an alternative to XML.<br />
History<br />
Douglas Crockford was the first to specify and popularize the JSON format. [1]<br />
JSON was used at State S<strong>of</strong>tware, a company co-founded by Crockford, starting around 2001. The JSON.org<br />
website was launched in 2002. In December 2005, Yahoo! began <strong>of</strong>fering some <strong>of</strong> its web services in JSON. [2]<br />
Google started <strong>of</strong>fering JSON feeds for its GData web protocol in December 2006. [3]<br />
Although JSON was based on a subset <strong>of</strong> the JavaScript programming language (specifically, Standard ECMA-262<br />
3rd Edition—December 1999 [4] ) and is commonly used with that language, it is considered to be a<br />
language-independent data format. Code for parsing and generating JSON data is readily available for a large variety<br />
<strong>of</strong> programming languages. json.org [5] provides a comprehensive listing <strong>of</strong> existing JSON libraries, organized by<br />
language.<br />
Data types, syntax and example<br />
JSON's basic types are:<br />
• Number (integer or real)<br />
• String (double-quoted Unicode with backslash escaping)<br />
• Boolean (true or false)<br />
• Array (an ordered sequence <strong>of</strong> values, comma-separated and enclosed in square brackets)<br />
• Object (a collection <strong>of</strong> key:value pairs, comma-separated and enclosed in curly braces)<br />
• null<br />
The following example shows the JSON representation <strong>of</strong> an object that describes a person. The object has string<br />
fields for first name and last name, contains an object representing the person's address, and contains a list (an array)<br />
<strong>of</strong> phone number objects.