Find Jobs
Hire Freelancers

perl code that requests a url and prints redirects

$30-100 USD

Slutfört
Publicerad ungefär 14 år sedan

$30-100 USD

Betalning vid leverans
I need some perl code that can take a LWP::UserAgent object and do a request on an HTTP::Request object, and if the request encounters HTTP redirect headers that the user-agent follows, it should print out each of the URLs that the user-agent is redirected to. For example: my $ua = LWP::UserAgent my $request = HTTP::Request->new('GET', '[login to view URL]'); # your code goes here Then the page <[login to view URL]> redirects to [login to view URL] and that page redirects to [login to view URL] So the code should output something like: redirected to <[login to view URL]> redirected to [login to view URL] In other words, if there's more than one redirect (this example has two), the code should output each redirect, not just the last one. I think this can be done with a "callback" function or something, but I can't find how to do it. This is probably a really simple problem (the solution is probably only about two or three lines of code) so you can either submit a bid, or if you want you can even submit a solution as a comment and I'll send you a tip of it works, since it's such a small job. ## Deliverables Basically as described above. ## Platform It's probably not a platform-dependent thing, but it has to work for me on Perl 5.8.8 with CentOS 5.4.
Project ID: 3283505

Om projektet

1 anbud
Distansprojekt
Senaste aktivitet 14 år sedan

Ute efter att tjäna lite pengar?

Fördelar med att lägga anbud hos Freelancer

Ange budget och tidsram
Få betalt för ditt arbete
Beskriv ditt förslag
Det är gratis att registrera sig och att lägga anbud på uppdrag
Tilldelad till:
Använd avatar
See private message.
$2 USD Om 14 dagar
5,0 (1 omdöme)
0,0
0,0

Om kunden

Flagga för UNITED STATES
Bellevue, United States
5,0
128
Verifierad betalningsmetod
Medlem sedan okt. 24, 2004

Kundverifikation

Tack! Vi har skickat en länk för aktivering av gratis kredit.
Något gick fel med ditt e-postmeddelande. Vänligen försök igen.
Registrerade Användare Totalt antal jobb publicerade
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Laddar förhandsgranskning
Tillstånd beviljat för geolokalisering.
Din inloggningssession har löpt ut och du har blivit utloggad. Logga in igen.