Many of us have become enamored with wireless devices. I’m addicted to my BlackBerry, and others I work with swear by their iPAQs or Jornadas. Wireless email is great, but I’m really looking for something else—a traffic update while I’m driving to work, for example. Some of us use wireless devices that offer full-blown browsers that can render almost any Web page (if you’re more patient than I am, this is a great feature). Some of us have Wireless Access Protocol-enabled (WAP-enabled) our cell phones, but the extremely small real estate on this device limits the amount of information that we can view at a time. Enter the wireless markup language (WML).

If you know HTML, you already know WML. WML is simple, and it follows the XML standard. A WML file travels to a WAP-enabled device just like an HTML page travels to your browser: A Web server receives a request for a file and serves the file to the client.

Below is a simple WML file we created to enter information about new recruits into our existing recruiting system. We wanted to add functionality to our Web-based recruiting application so that if employees encounter potential candidates for employment and they want credit for the referrals, they can use their WAP-enabled cell phones (or other devices) to enter the candidates into the system.





 
   
 

 

 

   

Last Name:


   

First Name:


   

EMail:


   

Work Phone:


   

Home Phone:


   

Cell Phone:


   

Notes:



   
     
       
       
       
       
       
       
       
     

   

 

You can see familiar HTML elements (e.g., the INPUT tags) in this WML document. Notice that within the GO tags, we set the fields for a form and have the data travel to the insertrecruit.asp page to submit the information into the recruiting system. At the beginning of this WML document, a reference points to the Document Type Definition (DTD) that defines the structure of WML. Parsers can easily determine whether you have created a well-formed WML document.

WML is lighter than HTML because you rarely use it to create formatting (you can’t do a whole lot on a cell phone’s display). Because it’s lighter and better formed, you can automatically generate WML files more easily than you can HTML documents. For example, if you’re using SQL Server 2000’s XML capabilities, you can build WML documents dynamically right from the database and serve them to WAP-enabled devices. You can generate forms directly out of SQL in WML format for users to enter information into SQL. In addition, you can transform data into WML format for viewing on WAP-enabled devices.

Don’t have a WAP-enabled device? WAP emulators are available that can run within your browser (for an example, go to the TagTag Web site). For information about setting up Microsoft IIS so that it serves WML files correctly, check out "Wireless Applications on IIS" in IIS Administrator, a monthly print newsletter from the same folks who bring you SQL Server Magazine and Windows 2000 Magazine.