答案:fieldset 提供了一种控件分组的功能,相对于optgroup它的潜在价值更强了,但是需要客户端设备的支持才能获得显示效果。相关属性:
title 标题
综合示例:
<?xml version="1.0"?>
<!doctype wml public "-//wapforum//dtd wml 1.1//en" "http://www.wapforum.org/dtd/wml_1.1.xml">
<wml><template>
<do type="options" label="back">
<prev/>
</do>
</template><card id="fields">
<p> field type:
<select title="field type">
<option onpick="#nested">nested</option>
<option onpick="#password">password</option>
</select>
</p>
</card><card id="nested">
<onevent type="onenterbackward">
<prev/>
</onevent>
<do type="accept" label="done">
<go href=></do>
<p>
<fieldset title="name">
first name:
<input title="first" name="fname"/>
last name:
<input title="last" name="lname"/>
</fieldset>
gender:
<select title="gender" name="gender">
<option value="male">male</option>
<option value="female">female</option>
</select>
</p>
</card><card id="done">
<p> $fname $lname is a $gender. </p>
</card><card id="password">
<onevent type="onenterbackward">
<prev/>
</onevent>
<do type="accept" label="done">
<go href=></do>
<p> input a password:<br/>
min 3 chars.
<input title="password" name="passwd" type="password" format="*m"/>
</p>
</card><card id="passwd_done">
<p> password was $passwd. </p>
</card>
</wml>
上一个:WAP网站的网关服务器应用形式解析
下一个:WAP聊天室机器人设计