From owner-freebsd-questions Mon Oct 8 17:27:26 2001 Delivered-To: freebsd-questions@freebsd.org Received: from cactus.fi.uba.ar (cactus.fi.uba.ar [157.92.49.108]) by hub.freebsd.org (Postfix) with ESMTP id 5F25037B401 for ; Mon, 8 Oct 2001 17:27:13 -0700 (PDT) Received: from cactus.fi.uba.ar (cactus.fi.uba.ar [157.92.49.108]) by cactus.fi.uba.ar (8.11.3/8.9.3) with ESMTP id f990PxG21629; Mon, 8 Oct 2001 21:26:01 -0300 (ART) (envelope-from fgleiser@cactus.fi.uba.ar) Date: Mon, 8 Oct 2001 21:25:59 -0300 (ART) From: Fernando Gleiser To: Chris Aitken Cc: Subject: Re: Perl, Expect and ^M's In-Reply-To: <5.1.0.14.2.20011009092449.03bac008@mail.ideal.net.au> Message-ID: <20011008212140.W13268-100000@cactus.fi.uba.ar> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, 9 Oct 2001, Chris Aitken wrote: > HI All, > > > Example - > > "The Cat Shat In The Hat^^Bad Cat^^Baaaaaad Cat" > > I pull this line out of the DB, and I need to be able to replace the ^^'s > with ^M's to look like the following > > "The Cat Shat In The Hat^MBad Cat^MBaaaaaad Cat" $string=~s/\^\^/\r/g; print $string Fer > > > > > I would love to be able to do this at the very end process and replace all > ^^'s with ^M's in the Expect script, but it might be that I need to do it > in the Perl script. > > > Anyone able to give me a slight nudge with the clue stick? > > > > > Thanks > > > Chris > > -- > Chris Aitken - Administration/Database Designer - IDEAL Internet > email: chris@ideal.net.au phone: +61 2 4628 8888 fax: +61 2 4628 8890 > __-----------------------------------------__ > It is said that if you line up all the cars in the world end to end, > some moron in a rotary will still to try and pass them > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message