Sep 11, 2003, 12:37 PM
Veteran / Moderator (17297 posts)
Sep 11, 2003, 12:37 PM
Post #2 of 5
Views: 852
Try;
my $relative;
$var =~ m/^http:\/\/(.+?)\/(.+?)/i and $relative = $2;
That should assign the bit after the first extention to $relative. Untested, but it looks like it should work.
Cheers
Andy (mod)
andy@ultranerds.co.uk
IMPORTANT: I've now moved to ultranerds.co.uk, and the .com will no longer work! Want to give me something back for my help? Please see my
Amazon Wish List GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500) Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin |
Pre-Made Template Sets |
FREE GLinks Plugins! Compare our different Plugin packages *new* Free CSS Templates
Andy: Sep 11, 2003, 12:38 PM