Web gadget built entirely from Web components—htmL, Css, and Javascript—displays
a greeting and photograph both customizable by the user; the photograph is accessed
via a uRL.
<?xml version=” 1.0” encoding=”UTF- 8” ?>
<Module>
<ModulePrefs title=”...”/>
<UserPref name=”myname”/>
<UserPref name=”myphoto”/>
<Content type=”html”><![CDATA[
<div id=”content_div”></div>
<style type=”text/css”>...</style>
<script type=”text/javascript”>
// Get userprefs
var prefs = new gadgets.Prefs();
function greet () {
// Get current time
var today = new Date();
var time = today.getTime();
var html = “”;
// Display appropriate greeting
html += ...
// Display photo if asked to
if ( prefs.getBool(“photo”) == true) {
html += ...
}
element.innerHTML = html;
}
...
gadgets.util.registerOnLoadHandler(greet);
</script>
]]>
</Content>
</Module>
Restful Web aPIs from major Web applications laid
the software foundations for Web 2.0.
service
amazon
Google
eBay
Yahoo!
Resource
Xforms Book
Search Hubbell+labrador
aSTeR
Browse autos
ample, weather forecasts were available
on Web 1.0, but XML HTTP Request
and the ability to asynchronously refresh the content displayed in a Web
page through JavaScript callbacks enabled Web sites to integrate weather
forecasts into the context of user tasks
(such as travel reservations). In addition
to being built from Web technologies,
a travel site that integrates a variety of
information sources in order to deliver
a complete task-oriented interface uses
the same Web technologies when constructing its constituent components.
Note that Web 2.0 is a result of applying Web technologies to the Web. Described differently, Web 2.0 is a conse-
quence of Web(Web()); or writing W for
the function Web, a more apt notation
for Web 2.0 would be W .
2
Web as Platform
The notion of the Web as a new platform emerged in the late 1990s with
the advent of sites providing a range
of end-user services exclusively on the
Web. Note that none of them had a parallel in the world of shrink-wrap software that had preceded the Web:
Portal. Yahoo! Web directory;
Shopping. Amazon online store;
Auction. eBay auction site; and
Search. Google search engine.
In addition to lacking a pre-Web
equivalent, each of these services
lived on the Web and, more important, exposed the services as simple
URLs, an idea later known as REpresentational State Transfer, or (REST)
ful, Web APIs.
16, 17 All such services not
only built themselves on the Web, they
became an integral part of the Web
in the sense that every Google search,
auction item on eBay, and item for sale
on Amazon were URL addressable (see
the table here).
URL addressability is an essential
feature of being on the Web. The URL
addressability of the new services laid
the foundation for Web 2.0, that is, the
ability to build the next generation of
solutions entirely from Web components. The mechanism of passing-in
parameters via the URL defined lightweight Web APIs. Note that in contrast
to all earlier software APIs, Web APIs
defined in this manner led to loosely
coupled systems. Web APIs like those
in the table evolved informally and
came to be recognized later as programming interfaces that could be
used to build highly flexible distributed Web components.
That all of these services heralded
publication of a new platform was reflected in the O’Reilly Hacks Series, including: Google Hacks10; Amazon Hacks
4;
Yahoo! Hacks3; and eBay Hacks.
22
The Web had thus evolved from a
Web of content to a Web of content
embedded with the needed user-in-teraction elements. Content embedded with user interaction evolved into
Web applications that could over time
be composed exclusively from Web
components. Being built this way and
living exclusively on the Web, the new
software artifacts came to form the
building blocks for the next generation of the Web. Together, they define
the Web as a platform with certain key
characteristics:
Distributed. Web applications were
distributed across the network; application logic and data resides on the
network, with presentation augmented
by the needed user interaction delivered to the browser;
Separable. The distributed nature
of Web applications forced a cleaner
separation between application logic
and the user interface than in the previous generation of monolithic desktop software;
56 CommunICatIons of the aCm | feBRuaRY2009 | vol. 52 | No. 2