my $templ=opentemplate('regform','normal'); substemplate($templ,'fullname',$arr[0]); substemplate($templ,'header',$arr[3]); # $link0="$arr[1]"; substemplate($templ,'link0',$link0); # foreach my $linknum ( 1 .. 10 ) { my $pos = $linknum * 2 + 2; my ( $text, $url ) = @arr[ $pos, $pos + 1 ]; my $link = ( ! $text or ! $url ) ? '' : "