[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] How do I flag a tab character



At 23.02 1998.05.01, Jon Jacob and Joetta Moon wrote:
>So, my question is: how do I flag a tab and get rid of them if I wanted
>to.  I figure I can use regex to do this, but I do not know the
>designation for a tab.  (The program actually resides on a Unix box.)

$text =~ s/\t//g;

That removes all tabs from $text.  Please see perlop.pod and perlre.pod
(using Shuck, or man perlop / man perlre / perldoc perlman / perldoc perlre
on Unix) for more information about s/// and /g and the special escape
sequence \t.  Also check out Mastering Regular Expressions by Jeffrey
Friedl, published by O'Reilly.

--
Chris Nandor          mailto:pudge@pobox.com         http://pudge.net/
MacPerl: Power and Ease (ISBN 1881957322), http://www.ptf.com/macperl/
%PGPKey = ('B76E72AD', [1024, '0824090B CE73CA10  1FF77F13 8180B6B6'])



***** Want to unsubscribe from this list?
***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch