
Spotlight Developing Mobile Wireless Applications Kris Read and Frank Maurer • University of Calgary hen we talk about Web content, we tion that lets wireless devices easily interact with typically use document metaphors — services and each other. It works over all major W saving our places with bookmarks, wireless networks and on all major mobile operating viewing and downloading pages, and so on. This systems. In fact, renowned wireless technology metaphor feels natural because it originated in providers such as Ericsson, Nokia, and Motorola are Web content, which is basically a collection of endorsing WAP for their 2.5G and 3G networks. electronic documents laid out in a format familiar Microsoft is also backing this mobile solution. from books, magazines, and other publications. Developers were slow to accept early WAP ver- In the mobile world, however, developers quick- sions because of a steep learning curve and incom- ly realized that “page” was not the best content patibility with existing Web content. WAP 2.0 metaphor. Small screens, limited bandwidth, and adopts existing Web standards, however, and spec- relatively little storage space prevent us from ifies how developers can best use them in a wire- building large, complex page layouts. We thus pre- less environment. WAP 2.0’s aim is to improve the fer to think of our content as a deck of cards. A user experience as wireless networks slowly expand card, like a cell-phone or PDA, is small and might to allow richer content and cheaper bandwidth. fit into the palm of your hand, for example. Also, like mobile device screens, individual cards offer Basic Features relatively little space to write on — though you can In theory, WAP 2.0 lets developers create applica- write a little on each card and flip between them tions that feature animation, streaming media, and whenever necessary. music downloads. WAP 2.0 displays color graphics, This deck-of-cards metaphor underlies nearly all provides location-specific content, and allows syn- content developed for mobile wireless technologies. chronization with a remote desktop PC. The goal is Standard, high-level application-development tech- to reduce development costs by letting developers nologies, which are available for most major hard- use standard tools to write applications for Web ware platforms, ease this development task because browsers and WAP clients at the same time. they’re optimized for the severe restrictions on a In WAP 2.0, developers write content in XHTML mobile device’s screen size, processing power, and using the XHTML Basic profile. (As the “XHTML battery life. Here, we discuss three major applica- Fundamentals” sidebar explains, XHTML is quite tion-development technologies: the wireless appli- easy to produce if you’re familiar with existing Web cation protocol (WAP), NTT DoCoMo’s i-mode, and development technologies.) WAP 2.0 also supports Sun’s Java 2 Micro Edition (J2ME). Each lets devel- cascading style sheets (CSS) for document format- opers create content for the current and upcoming ting. Users view XHTML content through a client generation of mobile wireless devices. device’s microbrowser; content is either stored local- ly or served up by XHTML-compatible Web sites. The Wireless Not all existing HTML Web pages can be viewed Application Protocol with this technology, however, and to make a Web WAP (www.wapforum.org) is a free, open specifica- site WAP-2.0 compatible, developers must follow IEEE INTERNET COMPUTING 1089-7801/03/$17.00©2003 IEEE Published by the IEEE Computer Society JANUARY • FEBRUARY 2003 81 Spotlight XHTML Fundamentals he Extensible HyperText Markup Lan- top to television set-top boxes and mobile HTML 4.0, but in fact some of its features Tguage is the W3C’s relatively new devices — the W3C has defined XHTML — such as frames or complex tables — are standardized Web document format. subsets, or profiles.WAP 2.0 developers use simply inappropriate for small devices. XHTML is based on XML and is ultimate- the XHTML Basic profile, which is a subset Developers can use XHTML Basic to cre- ly meant to replace HTML as the accept- of all available XHTML features. As the ate fully featured Web sites for ordinary ed Web page format. W3C states, it includes “the minimal set of Web browsers, but it’s also simple enough XHTML returns document formatting modules required to be an XHTML host to scale down to a mobile device’s limited to HTML’s original intentions by separating language document type,” including images, resources.There is even a tool, HTML Tidy, content and format. Because of browser forms, basic tables, and object support.This which helps convert HTML to XHTML; it’s platforms’ increasing range — from desk- might seem like a step backward from available at http://tidy.sourceforge.net. specific XHTML guidelines. Currently, few Web sites </style> are written in XHTML, but the number should grow </head> rapidly as developers and tools conform to World <body> Wide Web Consortium (W3C) standards. <img src=”icon.gif”/> WAP 2.0 includes multimedia messaging service <p>Here is some text.</p> (MMS), which lets users send messages that include <a href=”index.xhtml”>A Link</a> images and text. WAP supporters expect MMS to </body> further popularize short message service (SMS) in </html> Europe and North America. WAP 2.0 also includes WAP Push, which automatically delivers content with this example from WAP 1.x WML: to users, rather than waiting for them to request it. This is useful for services such as online auctions <?xml version=”1.0”?> or stock trading, where it’s important for users to <!DOCTYPE wml PUBLIC “//WAPFORUM//DTD 1.1//EN” receive information the moment something inter- “http://www.waponline.com/wml_1.1.xml”> esting happens. WAP 2.0 is backward compatible with the pre- <wml> vious standard, WAP 1.x, which uses Wireless <card title=”My Basic Card”> Markup Language (WML) rather than XHTML for <p> document formatting. WML is a set of specific <img src=”icon.wbmp” alt=”icon”/><br/> XML markup tags the WAP forum created specifi- This is some text.<br/> cally for WAP to represent typical mobile wireless <anchor>A Link. content. WML’s main disadvantage was that devel- <go href=”index.wml”/> opers had to create content independently of </anchor> HTML, or use some sort of translation process. </p> Although some of WML’s tags are similar to HTML, </card> the document elements are different and the fea- </wml> ture set is much smaller. Compare this example from WAP 2.0 XHTML Basic: In the XHTML Basic example, we define an HTML document with two parts: head and body. <?xml version=”1.0”?> The head includes at least a title, but here we also <!DOCTYPE html PUBLIC “-//W3C//DTD XHTML show how XHTML Basic supports CSS. The body Basic 1.0//EN” uses familiar HTML tags such as paragraph (p), “http://www.w3.org/TR/xhtml-basic/xhtml- image (img), and anchor (a). In the second exam- basic10.dtd”> ple, we define a WML document rather than an HTML document. Then, according to the deck-of- <html xmlns=”http://www.w3.org/1999/xhtml”> cards metaphor, we must define a series of cards. In this example, we define only one: it inclu1des <head> an image (img), a paragraph (p), and an anchor. <title>My Basic Page</title> Figure 1 shows a WAP 1.x document as viewed <style type=”text/css”> using 3tL’s free WAP Emulator, which lets PC users a { color: #0066FF } preview WAP documents without using a mobile 82 JANUARY • FEBRUARY 2003 http://computer.org/internet/ IEEE INTERNET COMPUTING Mobile Wireless Applications device. Although WML’s text syntax and image components are much like HTML, the anchor is not. When using WML, you can’t take HTML ele- ments for granted; you must ensure that any tags you use are part of the WAP Forum WML 1.x spec- ification (available at www.wapforum.org/what/ technical.htm). Unlike WML, XHTML Basic can be displayed in the latest major browser versions, including Internet Explorer, Mozilla, Netscape, and Opera. However, it does have some small eccentricities that you should keep in mind. Unlike HTML pages, for example, XHTML pages must include a <title> element. For mobile use, you should keep the title length rather Figure 1. A Wireless Access Protocol 1.x document as it appears on short. In XHTML Basic, you can also use some the 3tL WAP Emulator. WAP 1.x uses the Wireless Markup Language unconventional parameters to make your mobile rather than XHTML to format documents. application friendlier. One feature likely to be pop- ular, for example, is the accesskey parameter: ed i-mode because of its strong business model. A large base of i-mode content is available, and sev- <a href=”next.html” accesskey=”1”>Next</a> eral hardware devices support it as well. Because WAP is a protocol and i-mode is a ser- In this case, the accesskey parameter lets users vice, the two technologies are not necessarily com- press the “1” on their mobile keypad to click the petitors; DoCoMo is a member of the WAP Forum. Next link. Such shortcuts are smart and reason- In fact, according to WAP Forum’s CEO Scott ably universal in their compatibility with device Goldman, i-mode and WAP will likely converge hardware; if your browser doesn’t support the sometime in 2003 as both move toward W3C stan- accesskey parameter, it will simply ignore it. There dards support and seek the widest possible range are many other mobile-friendly parameters and of hardware vendors. tags in XHTML Basic; a complete listing is avail- able at www.w3.org/TR/xhtml-basic.
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages6 Page
-
File Size-