URL
A URL Utility object contains information about a URL string.
Supported Platform(s)
- BlackBerry OS 5.0+ |
- BlackBerry PlayBook 1.0+ |
- Ripple Emulator |
API | BB5.0 | BB6.0 | BB7.0 | PB1.0 | PB2.0 | BB10 | Ripple |
---|---|---|---|---|---|---|---|
getURLParameter | Y | Y | Y | Y | Y | Y | |
getURLParameterByIndex | Y | Y | Y | Y | Y | Y | |
host | Y | Y | Y | Y | Y | Y | |
port | Y | Y | Y | Y | Y | Y |
Configuration Document Settings
To use all of the API described for this object, you must ensure the following settings are in your configuration document: |
You must declare the feature element(s) below in your configuration document: |
Feature ID | BB5.0 | BB6.0 | BB7.0 | PB1.0 | PB2.0 | BB10 | Ripple |
---|---|---|---|---|---|---|---|
<feature id="blackberry.utils" /> | Y | Y | Y | Y | Y | Y |
Permission Elements (PlayBook and BlackBerry 10+) |
---|
This API does not require a <permission> element to be declared in the configuration document of your BlackBerry WebWorks Application. |
Functions
String
getURLParameter
(key : String)
Obtain the value of a parameter by key.
Supported Platforms | |
---|---|
- BlackBerry OS 5.0+ | |
- BlackBerry PlayBook 1.0+ | |
- Ripple Emulator |
Parameters | |
---|---|
key | The key of the parameter to be retrieved. |
Return:
An undefined object is returned if the key does not exist in the URL query.
String
getURLParameterByIndex
(index : Number)
Obtain the value of a parameter by index. The values are stored in the order they appear in the URL string.
Supported Platforms | |
---|---|
- BlackBerry OS 5.0+ | |
- BlackBerry PlayBook 1.0+ | |
- Ripple Emulator |
Parameters | |
---|---|
index | The index of the parameter to be retrieved. |
Return:
An undefined object is returned if the index is invalid.
Properties
Documentation generated by JsDoc Toolkit 2.4.0 on Sun Dec 30 2012 18:15:45 GMT-0500 (EST)