Creation WAP of a page
WML is so simply!
In this clause{article} I would like to share the experience of creation of wap-pages and in general a wap-site.
That the site could be looked through in a mobile browser not always the format *.html will approach, in fact absolutely small part mobile phones of it{him} displays. But all the same knowledge of language HTML to you will suffice. The supported format mobile browsers is *.wml. I have tested it{him} and I can say, that he even is easier than itself html. It can because here any scripts and special opportunities are not supported.
I shall try to explain to you all on a simple example of creation of wap-page in a format *.wml. So, we shall start:
First, it is necessary to say that standard browser Internet Explorer wml does not support a format and cannot display wap-page, therefore to work with such pages I recommend to get, for example, browser Opera. Here it will be possible predprosmatrivat` page. Also the text html-editor of pages is necessary - text because will fail to create page on the visual editor. I use program Microsoft Office FrontPage for creation of wap-pages. Here it is possible both to write a code, and the visual rector to try (in a case with propisaniem an initial code manually the visual editor will approach). You can find the program suitable for you.
As against computers mobile phones do not perceive all codings of fonts, these elements of pages therefore are rigidly limited. It is necessary in each page that all was correctly displayed, an initial code to begin with:
<? xml version = " 1.0" encoding = "UTF-8"?>
<! DOCTYPE wml PUBLIC " - // WAPFORUM // DTD WML 1.2 // EN " "http://www.wapforum.org/DTD/wml12.dtd">
The coding from this site is used almost with 90 % of Russian-speaking wap-sites, therefore to experience there is nothing. I do not think necessary to explain value of all it because knowing html the person so all will understand, instead of it is very good knowing is not necessary.
As well as in html the basic code of page is designated tegom <html> and </html>, ak the basic code of page <wml> and </wml> is here again designated.
<wml> </wml>
Certainly opening and closing ehtgo tega accordingly should be in the beginning and at the end of a code of page (in the beginning that is after codes for codings).
In tege head which here too is present, we write:
<head> <meta http-equiv = "Cache-Control" content = "no-cache" forua = "true"/> </head>
Something like tega body in *.wml is teg card. in it tege the maintenance{contents} of page is written. So, the code for card here is how looks:
<card id = "index" title = " the First wap-page ">
</card>
Here the name of page is written to a field "id", and in "index" its{her} heading is written. Between the first and second line of a code the code of the maintenance{contents} of page above certainly is written.
So, let's try write something, and then to put still the link and a picture.
We write:
<p align = "center">
It that all contents were on the center, in another way it is impossible, because not so will be displayed on the screen of mobile phones. The ambassador, in the end we shall close teg "p".
To write a plain text, simply we write it{him} on a separate line and in the end we put " <br/> ". And this teg does not begin anywhere, he simply speaks about the end of a line and is written in all lines in display. For example, we shall write:
WAP-page <br/>
Having written it, we shall receive stochku with words "Wap-page" in the middle.
Now we shall put the link, the most simple link. It can be made a code:
<a href = " http: // wap.site.ru/index.wml "> Main </a> <br/>
Here I think all understandably. Notice and in this line it is put teg " <br/> because it{him} put in each line, only not to a line of a code, and a line of the page.
I think, with the text and links have understood, now I shall say about pictures. To put a picture it is possible a code:
<img src = "logohallo.gif" alt = "wap.site.ru"/> <br/>
Here too likely all is understandable. You can svob put a picture, for this purpose will write instead of "logohallo.gif" the link to the picture. Pay attention, teg <alt> it is obligatory.
All that needed to be learned{be found out}, it teg which gives out contents through a line. As well as in html here it teg "p". That is for allocation of the text through a line it is necessary to enter his{its} code between:
<p>... </p>
So, I also have shown you codes for an insert of the test, a picture and the link. Be not surprised, but all this that is required to you for creation of the whole wap-site. Mobile browsers do not support neither scripts, nor tables, something similar.
But nevertheless it is necessary to see, that the code which at us has turned out will turn out from all it, that we now did{made}, so:
<? xml version = " 1.0" encoding = "UTF-8"?>
<! DOCTYPE wml PUBLIC " - // WAPFORUM // DTD WML 1.2 // EN " " http: // www.wapforum.org/DTD/wml12.dtd ">
<wml>
<card id = "index" title = " the First wap-page ">
<p align = "center">
WAP-page <br/>
<a href = " http: // wap.site.ru/index.wml "> Main </a> <br/>
<img src = "logohallo.gif" alt = "wap.site.ru"/> <br/>
</p>
</card>
</wml>
If you decide to see{overlook} page in a browser will not disassemble anything from words. All Russian letters will be as question marks. Therefore here job yet does not come to an end, has remained the most important part - translation of a code in a format wml. For this purpose there are such programs which translate this code, namely his{its} Russian letters on the necessary format. They very little and are difficult for finding, therefore specially for you, I have placed one elementary such "translator" and you can download it{him} here. Unpack both files in one folder and start the application. Here for you will open okoshko with two fields. In the first we enter our code and there and then in the next field there is a new variant of the same code, that that and is necessary for us. So, it will turn out:
<? xml version = " 1.0" encoding = "UTF-8"?>
<! DOCTYPE wml PUBLIC " - // WAPFORUM // DTD WML 1.2 // EN " " http: // www.wapforum.org/DTD/wml12.dtd ">
<wml>
<card id = "index" title = " RRS€RRS wap-SS S€RRRjoSR ">
<p align = "center">
WAP-SS S€RRRjoSR <br/>
<a href = " http: // wap.site.ru/index.wml "> R "?" RRRRS </a> <br/>
<img src = "logohallo.gif" alt = "wap.site.ru"/> <br/>
</p>
</card>
</wml>
Now all Russian letters will be correctly displayed. You can see{overlook} page and be convinced of it.

|