[an error occurred while processing this directive]
Forms Processor Advanced Commands
Contents   Index of Commands   Search the Forms Processor Docs   
indexThe index command returns the numeric offset into the source string of the string or character you are searching for.

index($haystack,"needle",[begin]);

Example:

#find a colon in the string:
# 'somename:age'

$haystack="Joe Blow:37";

$offset = index($haystack,":");
$name = substr($haystack,0,$offset);

$age = substr($haystack,$offset+1,length($haystack)-$offset);

format screen
$name you are $age years old!
.



See also:  substr ($string, start, length) function  length($string) function [an error occurred while processing this directive]