网络学院 w3pop社区 网络资源 IT新闻

w3pop.com :: 网络学院 :: WAP :: WML < setvar >标签

会员登陆

帐号

密码

回答

记住密码

忘记密码? 注册

WML < setvar >标签


作者:w3pop.com 翻译/整理:w3pop.com 发布:2007-04-29 浏览:694 :: ::

The <setvar> tag sets a variable to a specified value in a <go>, <prev>, or <refresh> task.
<setvar>标签为<go>、<prev>或<refresh>任务重的指定值设置一个变量。

Syntax
语法

<setvar name="somename" value="somevalue"/>

Attributes
属性

属性 描述
name cdata REQUIRED. Sets the name of the variable
必要参数。设置变量名称
value cdata REQUIRED. Sets the value of the variable
必要参数。设置变量值
class class_name Sets a class name for the element. The class name is case sensitive. An element can be connected to multiple classes. Multiple class names within the class attribute are separated by white space
为元素设置一个类名称。类名称是字母大小写不敏感的。一个元素可以被连接到多个类中。类属性中的多个类名称是通过空白符进行分隔的
id id_name  Sets a unique name for the element
为元素设置一个独立的名称

Examples
案例

<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN"
"http://www.wapforum.org/DTD/wml_1.1.xml">

<wml> 
<card> 
<p>
 <anchor>
  Go To Card 2
  <go href="#card2"> 
   <setvar name="x" value="30"/> 
  </go>
 </anchor>
</p> 
</card>
</wml>

评论 (0) All