LayoutHtmlItems

A collection of embedded HTML page items.

Instance Properties

Name Description Access
length number The number of objects in the collection. read-only

Methods

add(
[layer] ​[, at], reference ​[, withProperties])
 → HtmlItem
anyItem(
)
 → HtmlItem
count(
)
 → number
everyItem(
)
 → HtmlItem
firstItem(
)
 → HtmlItem
item(
index)
 → HtmlItem
itemByID(
id)
 → HtmlItem
itemByName(
name)
 → HtmlItem
itemByRange(
from, to)
 → HtmlItem
lastItem(
)
 → HtmlItem
middleItem(
)
 → HtmlItem
nextItem(
obj)
 → HtmlItem
previousItem(
obj)
 → HtmlItem
toSource(
)
 → string
add(
[layer] ​[, at=LocationOptions.UNKNOWN], reference ​[, withProperties])
 → HtmlItem
Creates a new HtmlItem
layer Layer The layer on which to create the HtmlItem. (Optional)
at LocationOptions The location at which to insert the HtmlItem relative to the reference object or within the container object. (Optional)
reference The reference object. Note: Required when the at parameter is before or after. Can accept: Document, Spread, MasterSpread, Page, Layer or PageItem. (Optional)
withProperties Object Initial values for properties of the new HtmlItem (Optional)
anyItem(
)
 → HtmlItem
Returns any HtmlItem in the collection.
count(
)
 → number
Displays the number of elements in the HtmlItem.
everyItem(
)
 → HtmlItem
Returns every HtmlItem in the collection.
firstItem(
)
 → HtmlItem
Returns the first HtmlItem in the collection.
item(
index)
 → HtmlItem
Returns the HtmlItem with the specified index or name.
index The index or name. Can accept: Long Integer or String.
itemByID(
id)
 → HtmlItem
Returns the HtmlItem with the specified ID.
id number The ID.
itemByName(
name)
 → HtmlItem
Returns the HtmlItem with the specified name.
name string The name.
itemByRange(
from, to)
 → HtmlItem
Returns the HtmlItems within the specified range.
from The HtmlItem, index, or name at the beginning of the range. Can accept: HtmlItem, Long Integer or String.
to The HtmlItem, index, or name at the end of the range. Can accept: HtmlItem, Long Integer or String.
lastItem(
)
 → HtmlItem
Returns the last HtmlItem in the collection.
middleItem(
)
 → HtmlItem
Returns the middle HtmlItem in the collection.
nextItem(
obj)
 → HtmlItem
Returns the HtmlItem whose index follows the specified HtmlItem in the collection.
obj HtmlItem The HtmlItem whose index comes before the desired HtmlItem.
previousItem(
obj)
 → HtmlItem
Returns the HtmlItem with the index previous to the specified index.
obj HtmlItem The index of the HtmlItem that follows the desired HtmlItem.
toSource(
)
 → string
Generates a string which, if executed, will return the HtmlItem.