RAD function: strchrin

A RAD function that inserts copies of a string into another string.

Function

strchrin

Format

$L.void=strchrin($target, $index, $source, $copies)

Parameters

The following parameters are valid for the strchrin function:

Parameter Data type Description
$L.void= Not applicable. A syntax requirement only, does not affect the outcome of the function.
$target String The string being modified.
$index Number The position in $target to begin inserting copies of $source.
$source String The string to be inserted into $target.
$copies Number The number of copies of $source to insert into $target.

Example

$target="Hewlett-Packard"
$index=4
$source="falcon"
$copies=2
$L.void=strchrin($target, $index, $source, $copies)

After execution, the value of $target is Hewfalconfalconlett-Packard.