Retrieves the value associated with a specified key.
getItem( key ) → {String}
Name | Type | Description |
key | String | String key corresponding to the requested value. |
A String value corresponding to the key, or null if either the key is not known, or if the key exists but its value was set to null.
[/reference/refbody/section/sectiondiv {""})Type:
String
(sectiondiv]// Create the SUP Storage var store = new hwc.SUPStorage ("one"); store.setItem ("foo", "bar"); // add an item. result = store.getItem ("foo"); // will returns "bar". result = store.getItem ("foo1"); // foo1 does not exists; will return null.