[Cover] [Previous Section] [Next Section] [Index]

Current chapter: Using Images in HDML
Section 30 out of 67 total sections , Section 2 out of 3 sections in this chapter


Using images in HDML

To include an image in formatted text, you use an <IMG> statement. You can include an <IMG> statement anywhere in formatted text:

The image appears wherever you place the <IMG> statement in the text.

The syntax for the <IMG> statement is:

Statement  Description 
<IMG  

Beginning of the image header.  

ALT=alt_text  

Text to display if the image can't be displayed (if the phone does not support images or the image content can't be found). 

SRC=image_url  

The URL of the image to display. If you specify a valid name for the ICON option, the device ignores this option. 

ICON=icon_name  

The name of a local image to display. If the UP.Browser cannot find the image in ROM, it retrieves it from the UP.Link server. 

See the HDML Language Reference for a list of the icon names you can specify for this option. 

>  

 



Supported image formats and sizes

The UP.Link and UP.SDK 3.1 releases support only the 1-bit BMP image format. It is up to the HDML service to ensure that images fit on the device display. For information on determining a device's display size, see Retrieving subscriber, device, and UP.Link information. Images that are too large for the display (but still within the maximum deck size) are cropped by the device.



Example of images in choice entries

The following HDML deck uses images in both display and choice cards (see Figure 4-1).

FIGURE  4-1.     Images in display and choice cards



Example of images in softkey labels

The following HDML deck illustrates all three ways you can use images in a card:

The interface created by this deck is shown in Figure 4-2.

FIGURE  4-2.     Images in display and choice cards


IMPORTANT     Because the SOFT1 and SOFT2 function keys do not have default labels, you must specify the LABEL option within your <ACTION> statement if you use an image for either of these keys. The UP.Browser will use this label if it cannot find the image you specify.


[Cover] [Previous Section] [Next Section] [Index]

Current chapter: Using Images in HDML
Section 30 out of 67 total sections , Section 2 out of 3 sections in this chapter


Copyright © 1999, Unwired Planet, Inc. All rights reserved.