Application:Display user-created characters on the web page.
● CGI Program Name
bmp2png - Convert Ming Bitmap file into Portable Network Graphic (PNG) file.
ttf2png - Convert the Formal Style Script True Type file into PNG file.
● Application Procedur
-
In the space where Chinese Character is to be displayed, input
<img src="https://www.cns11643.gov.tw/cgi-bin/bmp2png">
or
<img src="https://www.cns11643.gov.tw/cgi-bin/ttf2png">
-
Add the following parameters after bmp2png or ttf2png:
Name of Parameter |
Application |
Example |
page |
The number of character planes of CNS 11643;bmp2png can use 3 - 7 and 15, ttf2png can only use 3 - 4. |
page=3 |
number |
The CNS Code of the character (CNS 11643). |
number=424E |
fontsize |
The size of the character; pre-set value is 12 x 12, equivalent to 9 points in Windows. |
fontsize=12 |
bgcolor |
Background color of the character. |
|
fgcolor |
Color of the character. |
|
● Practical example of application
If adding on the web page 王建 的「火宣」,write:
<img src="https://www.cns11643.gov.tw/char/kai/96/714a.png">
● CGI parameter generators
To allow users to more easily obtain parameters of the CGI program, we have provided a simple form below. Select CNS character plane and enter the character code, then select font size and press the button to obtain complete CGI parameters.
|