http://www.perlmonks.org?node_id=831559


in reply to split a string at a defined index

Hi AvantA,

Try this

$str="www,google,yahoo,345"; my ($var1,$var2)= $str =~/^([^\n]+),([^\n]+)$/;

Punitha

Replies are listed 'Best First'.
Re^2: split a string at a defined index
by smokemachine (Hermit) on Mar 29, 2010 at 10:58 UTC