Method WMLCard():task() Professional

Create a task.

Syntax
:task( [<cLabel>], ;
       <cURL>    , ;
       [<cType>] , ;
       [<cOptions>] ) --> self
Parameters
<cLabel>
The optional parameter <cLabel> becomes the value of the label attribute in the WML <do> tag.
<cURL>
The parameter <cURL> becomes the value of the href attribute in the WML <go> tag.
<cType>
The optional parameter <cType> becomes the value of the type attribute in the WML <do> tag.
<cOptions>
The optional parameter <cOptions> is a character string that is inserted into the WML <do> tag.
Return

This method returns the object executing the method (self).

Description

The method specifies a task in a card which usually defines how a user can navigate beween cards in a deck or between WML documents. The parameter <cURL> indicates the target of the task, i.e. this is what the mobile device is to load when the user activates the link indicated with <cLabel>.

The parameter <cType> defaults to "accept" (=positive acknowledgement). Other valid types for a task are "prev" (=backward navigation), "help" (=request for help) and "refresh" (=reload current document).

WML output when <cURL> is a #cardID or a http: link:

<do type="cType" [label="cLabel"] [cOptions]> 
 <go href="cURL"/> 
</do> 

WML output when <cURL> is a predefined task such as <prev/>:

<do type="cType" [label="cLabel"] [cOptions]> 
<prev/> 
</do> 

Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.