in reply to Removing a text element from the middle of a string

why not use
$s=split(/,/, $line)[1];
or something similar? It seems like this is what you really want.