in reply to LWP::Simple relative URI bad bad bad. ;)
What you want to do is too complicated for LWP::Simple. :) At this point you should switch to LWP::UserAgent, HTTP::Request, and HTTP::Response, to get more control over your requests and how you handle the responses. In addition to those modules, the LWP bundle also comes with the lwpcook documentation, which contains lots of examples for LWP.