Date: Thu, 11 May 2000 18:42:59 +0200 From: "Dan Larsson" <dl@tyfon.net> To: <questions@freebsd.org> Subject: regexp driving me nuts, help needed! Message-ID: <NEBBJANJCNNAKCPFKHHFEEENCCAA.dl@tyfon.net>
next in thread | raw e-mail | index | archive | help
I need to get the domain and tld from an url. this my idea of what would match and return 'domain.com': echo http://www.domain.com/html.asp | sed -e 's/\([\.a-zA-Z0-9]+[a-zA-Z]{2,3}\)/\1 /g' But that's not what sh thinks ( it returns the whole url ) What regexp should I use to get the desired result? Regards ------------ Dan Larsson To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?NEBBJANJCNNAKCPFKHHFEEENCCAA.dl>