Gossamer Forum
Home : General : Perl Programming :

How to...

Quote Reply
How to...
Hi, just a little help pls...
how do you put:
Code:
/[^\/]+$/; # find anything after the last / to end of line
into
Code:
my ($input) = $_[0];
$input =~ s,\\, : ,g; #this is the line I wanted to replace with the above one
return $input;
thanks

Robbie
Quote Reply
Re: How to... In reply to
Try this:
$input =~ s,[^\,]+$,;

In your code, the forward slashes "/" are substitued by commas ","