namedItem Method
Note: This documentation is preliminary and is subject to change.
Retrieves a storage area from the collection, by name.
Syntax
oItem = StorageList.namedItem(sDomain)
Parameters
sDomain Required. The domain name of origin.
Return Value
Returns the named storage list, or an empty list if not found.
Remarks
If the browser has not allocated a global storage area for the specified sDomain in the current browsing context, a new storage area for that origin is created.
Each domain and subdomain has its own separate global storage area. Subdomains can access the storage areas of parent domains, and domains can access the storage areas of subdomains. For example,
globalStorage['example.com']
is accessible toexample.com
and any of its subdomains. In reverse,globalStorage['www.example.com']
is accessible toexample.com
, but not other subdomains, such asmail.example.com
.
Standards Information
This method is defined in HTML 5
.
Applies To
StorageList
See Also