HTML and CSS Reference
In-Depth Information
latitude : Geographic coordinates in decimal degrees
longitude : Geographic coordinates in decimal degrees
altitude : Height in meters
accuracy : Accuracy levels of latitude and longitude coordinates in meters
altitudeaccuracy : Accuracy levels of altitude in meters
heading : Direction of travel of hosting device in degrees (most relevant to a mobile
device)
speed : Current ground speed of hosting device in meters/second (most relevant to a
mobile device)
If you have a mobile device, you can experiment with dif erent headings and speed — with
someone else driving! All the geolocation properties can be sent to a form for display if
you want. If used with a mobile device, you'll need either an open-socket server or frequent
browser/page refreshing.
A i nal aspect of geolocation is the use of the Google Earth plug-in. Figure 15-3 shows a
revised version of the basic Web page with the plug-in that can generate a 3-D view of the
mapped area.
You can update the sample Web page to the same dimensions by giving the <iframe> tag
the following attributes: width=500 height=400 . h en click the Earth option at the top
of the map area. If your browser has the plug-in, it will show the 3-D view. Otherwise, it'll
of er you a chance to download the plug-in and install it on your browser.
311
STORAGE IN HTML5
Other than cookies that store data on the user's browser, when you think about storage,
typically a database and other programs like PHP and ASP.NET come to mind. However, the
HTML5 DOM now has a storage object that can be used in four contexts:
Session storage
Global storage
Local storage
Database storage
Not all browsers support all these storage contexts, but as browsers are continuously updated
to include HTML5, they include more contexts. At the time of this writing, Safari, Chrome,
and Opera supported all the contexts except global storage; Firefox supported them all except
database storage.
 
Search WWH ::




Custom Search