Then we have to install it. However, in activestate's distribution there is
the specific modul preinstalled.
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: "Perl Beginners" <[EMAIL PROTECTED]>
Sent: Friday, September 05, 20
Sorry, lack of sleep.. but isn't File::Basename usally installed in the
standard Perl install?
Denis
On Fri, 5 Sep 2003 [EMAIL PROTECTED] wrote:
> On Thu, 4 Sep 2003 [EMAIL PROTECTED] wrote:
>
> > basename is more convenient i think. What do you say?
> >
> Only if you can load the module on t
On Thu, 4 Sep 2003 [EMAIL PROTECTED] wrote:
> basename is more convenient i think. What do you say?
>
Only if you can load the module on the system. running into issues here at
work where I can load modules (security llama's)
Denis
>
> Quoting [EMAIL PROTECTED]:
>
> > On Mon, 1 Sep 2003 [EMA
you "file.txt" as output.
Hope you will find it usefull.
/Freddy
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: "Perl Beginners" <[EMAIL PROTECTED]>
Sent: Thursday, September 04, 2003 5:20 AM
Subject: Re: cutting a string
basename is more convenient i think. What do you say?
Quoting [EMAIL PROTECTED]:
> On Mon, 1 Sep 2003 [EMAIL PROTECTED] wrote:
>
> > What is the function of cutting a string from a point until the last
> character?
> >
> > For example
> > $string="C:/progra~1/directory1/directory2/file.txt";
>
--On Wednesday, September 03, 2003 9:20 PM -0600 [EMAIL PROTECTED] wrote:
On Mon, 1 Sep 2003 [EMAIL PROTECTED] wrote:
What is the function of cutting a string from a point until the last
character?
For example
$string="C:/progra~1/directory1/directory2/file.txt";
i want to find the last backslash
denis <[EMAIL PROTECTED]> offered this solution:
: why not try this?
:
: #!/usr/bin/perl
: my @test='';
: my $string = "C:/test/me";
: @test = split('/',$string);
: print "@test\n";
: print "$test[$#test]\n";
The last item of an array can be retrieved
using an index of -1.
print "$test[$#
On Wed, 3 Sep 2003 [EMAIL PROTECTED] wrote:
> On Mon, 1 Sep 2003 [EMAIL PROTECTED] wrote:
>
> > What is the function of cutting a string from a point until the last character?
> >
> > For example
> > $string="C:/progra~1/directory1/directory2/file.txt";
> >
> > i want to find the last backslash
On Mon, 1 Sep 2003 [EMAIL PROTECTED] wrote:
> What is the function of cutting a string from a point until the last character?
>
> For example
> $string="C:/progra~1/directory1/directory2/file.txt";
>
> i want to find the last backslash (/) of the string and keep the sequence
> following it (fil
As long as the format of what you want (file.txt) remains the same you
could do the following:
($stuffattheend) = $string =~ /\/(\w+\.\w+)$/;
Danny
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Monday, September 01, 2003 11:41 AM
To: Perl Beginners
Subject:
<[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> What is the function of cutting a string from a point until the last
character?
>
> For example
> $string="C:/progra~1/directory1/directory2/file.txt";
>
> i want to find the last backslash (/) of the string and keep the sequence
> foll
11 matches
Mail list logo