in reply to Variable as split delimiter

Let perl do the escaping for you:

my $delimiter = quotemeta '|';