Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: A Better Guten Split

by ikegami (Patriarch)
on Dec 01, 2009 at 00:35 UTC ( [id://810292]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $split = join '/', split //, $id;
    substr($split, -2, 2, '');
    my $url = "$base_url/$split/$id/$id-h/$id-h.htm";
    
  2. or download this
    substr( ( my $split = join '/', split //, $id ), -2, 2, '');
    my $url = "$base_url/$split/$id/$id-h/$id-h.htm";
    
  3. or download this
    ( my $url = join '/', split //, $id ) =~
        s{(.*)/}{$base_url/$1/$id/$id-h/$id-h.htm}s;
    
  4. or download this
    my $url = join('/', 
        $base_url,
    ...
        "$id-h",
        "$id-h.htm"
    );
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://810292]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (4)
As of 2024-04-19 20:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found