Guest_imported
New member
- Jan 1, 1970
- 0
I want just the output of the page name here but cant get this to work right.
Some of the pages are index.cfm or index.html or webpage.htm or home.cfm etc..
I just to eliminate the .cfm or .html or .htm at the end when I print.
I can do it with split command but
want to do this with regular expressions.
[tt]
use strict;
my $var="index.html";
$var =~ /(*.+).html?cfm?htm/;
chomp;
print "$1\n";[/tt]
Some of the pages are index.cfm or index.html or webpage.htm or home.cfm etc..
I just to eliminate the .cfm or .html or .htm at the end when I print.
I can do it with split command but
want to do this with regular expressions.
[tt]
use strict;
my $var="index.html";
$var =~ /(*.+).html?cfm?htm/;
chomp;
print "$1\n";[/tt]