Matthew Arrowsmith wrote: > > > No, you have to use a regular expression: > > > > my ( $DOM_NAME, $TLD ) = $domain =~ /(.+)\.(.*)/g; > > Looking at the domain fred.org.uk you would get fred.org and uk as your > (.+) will do a greedy match. I think you want (.+?).
No, this is what the original poster wanted. (see subject line and OP) > Also, thinking about it, why do you want to do that globally (/g)? The > strings you gave before only had on domain in them. Even if they had > two you are putting the results into scalar vars and would lose some of > the results. It will work with or without the /g modifier. John -- use Perl; program fulfillment -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]