User Guide

Table Of Contents
getURL() 17
Flash Lite 1.0 recognizes only the HTTP, HTTPS, mailto, and tel protocols. Flash Lite 1.1
recognizes these protocols, and in addition, the file, SMS (short message service), and MMS
(multimedia message service) protocols.
Flash Lite passes the call to the operating system, and the operating system handles the call
with the registered default application for the specified protocol.
Only one
getURL() function is processed per frame or per event handler.
Certain handsets restrict the
getURL() function to key events only, in which case the
getURL() call is processed only if it is triggered in a key event handler. Even under such
circumstances, only one
getURL() function is processed per event handler.
Example
In the following ActionScript, the Flash Lite player opens mobile.macromedia.com in the
default browser:
myURL = "http://mobile.macromedia.com";
on(keyPress "1") {
getURL(myURL);
}
You can also use GET or POST for sending variables from the current timeline. The following
example uses the
GET method to append variables to a URL:
firstName = "Gus";
lastName = "Richardson";
age = 92;
getURL("http://www.macromedia.com", "_blank", "GET");
The following ActionScript uses POST to send variables in an HTTP header:
firstName = "Gus";
lastName = "Richardson";
age = 92;
getURL("http://www.macromedia.com", "POST");
You can assign a button function to open an e-mail composition window with the address,
subject, and body text fields already populated. Use one of the following methods to assign a
button function: Method 1 for either Shift-JIS or English character encoding; Method 2 only
for English character encoding.
Method 1: Set variables for each of the desired parameters, as in this example:
on (release, keyPress "#"){
subject = "email subject";
body = "email body";
getURL("mailto:somebody@anywhere.com", "", "GET");
}