Seems like to me you should just change the last capture to be [^\n] as in
$data =~ /http:\/\/(.*?):(.*?)@([^\n]*?)/g; or something like that. -----Original Message----- From: Kris G Findlay To: [EMAIL PROTECTED] Sent: 11/12/2001 5:04 PM Subject: regex problem question if i have $data = "http://user:[EMAIL PROTECTED]\nhttp://www.someothersite.com" and run regex $data =~ http:\/\/(.*?):(.*?)@(.*?)/g how do i stop it from being so greedy and take the whole line ? -- ----------------------------------- K.G.Findlay [EMAIL PROTECTED] Knight Shift (Web/Software Design) "Your only young once, but you can be imature forever" ----------------------------------- -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]