Declaring A WML Document
When you are creating a WML document all you need is notepad or another text editor, just like for HTML. The first thing you should enter is:
<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">
<wml>
this tells the phone that it is interpreting a WML document and which WML standards it is using.
Cards
Instead of having pages, WAP sites have cards. These are what is displayed on the screen at one time, just like a page. More than one card can be inserted in each WML document. To declare a card, insert the following:
<card id="index" title="My WAP Site" newcontext="true">
This will make a card with the ID index (used for linking) and will display the text:
My WAP Site
at the top of the screen.
Closing Tags
Unlike with HTML, it is extremely important to close WML tags. If you do not, a page will certainly not work. You must close both the <card> and <wml> tags:
</card>
</wml>
|