The Mobile Developer
by Eric Giguère, February 1, 2000
Will WAP Complicate Our Lives?
I'm currently reading Steve Mann's book
Programming Applications with the Wireless Application Protocol,
which is a good introduction to WAP and certainly easier to digest
than the Official Wireless Application Protocol hardcover reference
that is sitting on my shelf. I thought it would be a good idea to
figure out what all the fuss is about and if and how WAP will
affect me.
My first thought, I must admit, is that WAP complicates my life.
If you're involved with creating Web content, whether it be web
pages or web applications, WAP is going to add yet another
twist to your job. Forget about worrying if your users are
using Netscape Navigator or Internet Explorer, now you're
going to have to worry about cellphone and other mobile users
accessing your site via their WAP microbrowsers. All that
carefully crafted HTML and JavaScript won't do them much good.
I'm not going to worry about it, you say, because the
gateways will handle it all for me. Maybe. There's no
doubt that gateways will be able to transform vanilla HTML
into WML, the WAP markup language, because they're both
SGML derivatives and WML looks a lot like HTML. The same
is true for vanilla JavaScript, since WMLScript, the WAP
equivalent, is derived from it.
The problem I see is that it's very rare for websites to
use vanilla HTML or JavaScript. Even the simplest site,
for example, uses HTML tables to lay out its elements.
The Web Style Guide
by Patrick J. Lynch and Sarah Horton (a great resource,
by the way) states it quite simply: "Tables are currently the
only HTML option for page layout." With tables you can ensure
that no line goes beyond a certain length. You can also
carefully position images and related text relative to the
main part of a page. There's a fundamental assumption that
you're dealing with about 500 pixels of horizontal space,
and some websites are even going beyond that. Cellphones
simply don't have this kind of display space.
If the gateway can't do a good job of transforming your
website, then you'll have to do it yourself. Maybe not
now -- the critical mass isn't there, at least in
North America. But it will arrive at some point, so
you might as well start thinking about it. If you want
to address the two sets of users, you'll need to effectively
build two websites, one for WAP users and one for non-WAP
users. This is why I think WAP complicates my life.
Of course, not all complications are bad. Some will see
this as an opportunity to develop tools to deal with
the dual-view problem. Maybe you'll end up programming
in WML and WMLScript and run your code through a tool
to transform it to HTML and JavaScript. I'm sure such
a tool would produce a useable web page, but would it
look as good as a "native HTML" page? Probably not.
There's a Chinese curse that goes something like this:
May you have an interesting life. With WAP,
things are bound to be interesting.
Eric Giguère is the author of
Palm Database Programming: The Complete Developer's Guide
and an upcoming book on the Java 2 Micro Edition. He works
as a developer in Sybase's Mobile & Embedded Computing division.
Visit his website at www.ericgiguere.com
or send him mail at ericgiguere@ericgiguere.com.