in reply to newbie split question
will spit out#!/usr/local/bin/perl my @items = split /\",\"/, '"alpha","beta","gamma"'; foreach (@items) { print "$_\n"; }
Just make sure you deal with those at some point; I'd probably do something like substr $string, 1, -1 If there's extra garbage in the string, maybe like <CODE>s/\"(.*)\"/$1/</CODE"alpha beta gamma"
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
RE: Re: newbie split question
by Anonymous Monk on May 06, 2000 at 17:52 UTC | |
by Adam (Vicar) on May 08, 2000 at 22:45 UTC |