Contents

arrayInsertAt

Description

Inserts a value at the specified position in the array.
If the element is inserted before the end of the array, Railo shifts the positions of all elements with a higher index to make room.

Usage Syntax

arrayInsertAt(array array,number position,any value): boolean

Return Information

Return Type
boolean

Arguments

The arguments for this function are set. You can not use other arguments except the following ones.

Name Type Required Description
array array Yes The array which will have the new element inserted.
position number Yes The numerical index in the array where the new element will be inserted.
Must be less than or equal to the length of the array.
Remember CFML arrays start at 1 not 0.
value any Yes value to insert

category Categories: