Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 9 Feb 2001 16:08:49 +0700
From:      John Indra <john@office.naver.co.id>
To:        freebsd-questions@freebsd.org
Subject:   Crafting Perl RE...
Message-ID:  <20010209160849.A97806@office.naver.co.id>

next in thread | raw e-mail | index | archive | help
Hi...

Simple question but I don't know the answer. Suppose I have this string:
somefile.ins.jpg. I want to craft a Perl RE so it captures the jpg part. I
try this RE:

$string =~ m#\.(.*)$#

Unfortunately $1 captures ins.jpg, not jpg as I want.

What RE to get it right?

Thanks...

/john



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?20010209160849.A97806>