How to make mobile page (site for cellular phone)
When it comes to be able to make the homepage for the standard PC, Let's make a mobile page (page for the cellular phone). If the language uses CHTML, any cellular phone is first displayed without trouble.
Page for the cellular phone
What one is the page (site) for the cellular phone? It is a page only of the character (site) to be brief. The communication method is packet transmission. The character-code is Shift-JIS, and if capacity on CHTML and page 1 uses neither the image, music nor the pictograph within 5KB as for the description language, the page that can be used with all almost portable terminals can be done.
What is CHTML (Compact HTML)?
It is a description language for portable terminals such as cellular phones and PDA(Personal Digital Assistant). It is the one that an extra specification was excluded from HTML.
Anyway, there is no problem if only basic tag that writes the character as follows is used.
Example of mobile page written with CHTML
The mobile page written with the following CHTML is an example of the page to tell only sentences. It is informed that it is Compact HTML in the first line a browser.
It is informed that text character's code is written with Shift_JIS in the meta tag in the head tag them. Naturally, the character-code is written by shift JIS. "Description meta name =" and "Keywords meta name =" are SEO measures. The title (TITLE tag) is written putting an adequate title on the page.
In the body tag, finding (H1-H6 tag) is put as the person and the search robot see easily. Sentences are composed by using the paragraph (P tag) putting the paragraph on sentences. It changes line by changing line (BR tag) to change line moderately though you may not change line excluding the paragraph. The link (A tag) is used to link.
AAlmost usual sentences can be made only from this. There is no problem even if P tag is not used and sentences are written without tag.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD Compact HTML 1.0 Draft//EN"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS"> <meta name="description" content="***********"> <meta name="keywords" content="***,***,***"> <title>*****</title> </head> <body> <h1>*****</h1> It is OK without tag <p>writes sentences by usually using P tag.</p> <br> <a href="***">*****</a> </body> </html>
Other tag that can be used with CHTML 1.0
The main tag that can be used with CHTML 1.0 besides the above-mentioned is as follows.
- CENTER center justification
- DIV position specification Align = "left | center | right"
- HR separator line(horizon)
- PRE solid writing(The source is displayed as it is. )
- Specification of UL list
- Content of LI list
- "URL" action = FORM form Method = "get | post"
- INPUT text input field, radiobutton, and check box
- The IMG image display GIF and the JPEG image can be used without trouble.
Google AdSense for cellular phone
The Google AdSense for the cellular phone is described with PHP. The extension is made php or the extension describes that PHP operates html in the htaccess file. Naturally, if it is not a server that can use PHP, the Google AdSense for the cellular phone cannot be displayed.
When I experimented, the Google AdSense for mobility was displayed as for the page described by SSI. If include can be done by the servers end, it seems to operate.
Only the advertisement must be displayed, an advertising frame must not be displayed, and the possibility of becoming the violation of the program policy must note that it is if you do not label accessory, "Advertisement" or "Sponsor link" after the advertisement ..the delimitation of the horizon (HR tag).. when you put the Google AdSense on the mobile page made with CHTML.
It is noted to be able to put the Google AdSense for mobility only by one per every page. Moreover, please note that a double advertisement is put up only at the bottom of a page.
It is convenient to take the external file of the Google AdSense by the include function of PHP.
What is PHP does execute the script described in the HTML document by PHP of the server, and as a result It is the one passed to Web a browser as HTML data.
To To call external file (mobile_adsense.inc) of the Google AdSense that exists in the same folder in the PHP file (The extension is usual php), as follows is done.
<?php include("mobile_adsense.inc"); ?>
The extension of the file that does include also cares also about inc, htm or neither html nor php. It is convenient to describe the above-mentioned HR tag in this file.
The grammar of CHTML is diagnosed.
When a mobile page is completed, let's check the grammar of CHTML on the HTML grammar diagnosis page. Let's usually assume that it only has not to be a serious error though it becomes a considerably severe diagnostic outcome.