Openwave SDK

Although a complete discussion of WML and WMLS is beyond the scope of this book, it would be a useful exercise for you to create your own WML program and test it on a live Web server. This requires the following two items:

  • Access to a Web server (IIS or Apache both work well)

  • A development tool to test the programming

For the development tool, we recommend that you download and use the latest version of Openwave’s SDK, which is freely available to developers at http://www.openwave.com. Once you install this program, you simply need to specify where the files will be stored.

To tune the Web server, you must add the MIME (Multipurpose Internet Mail Extensions) settings. MIME enables your Web server to handle specific file types. If the file extension is not listed, the Web server will reject any requests for a file of that type.

IIS Setup

1.
Click Start→Settings→Control Panel→Administrative Tools→Internet Information Service.

2.
Right-click on the Web Sites directory and select Properties.

3.
Click the HTTP Headers tab.

4.
Click the File Types button (see Figure 3.7).

Figure 3.7. IIS File Types dialog.


5.
Click the New Type button.

6.
Enter wml (or wmls ) in the Associated Extension box.

7.
Enter text/vnd.wap.wml (or text/vnd.wap.wmlscript ) in the Content Type (MIME) box (see Figure 3.8).

Figure 3.8. IIS File Type entry dialog box.


8.
Click OK→OK→OK.

9.
Restart IIS.

Apache Setup

1.
Click Start→Find→Files or Folder and search the C: drive for mime.types

This file will typically be located under the C:Program FilesApache GroupApacheconf directory.

2.
Open the file and find the following lines:
application/vnd.wap.wbxml  wbxml 
    application/vnd.wap.wmlc    wmlc 
    application/vnd.wap.wmlscriptc   wmlsc 
    application/vnd.wap.wbxml    wbxml 



3.
After the application/vnd.wap.wmlc wmlcline insert the following lines:
application/vnd.wap.wml        wml 
application/vnd.wap.wmlscript    wmls 



4.
You could also edit the existing wmlc and wmlscriptc lines and remove the trailing c.

5.
Restart Apache.

As you can see, it is not difficult to get WML running on a Web server. There is no software or hardware to install. The fun and challenging part for you will be creating the WML pages and testing the Web server with either a real PCS or a virtual PCS device.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset