The user agent string clearly wasn't the problem here as YourMother shows. However, claiming to be different browsers is not "nutty".

I've done maybe 1/2 dozen LWP programs and I've found that fiddling with the agent string by claiming to be something really stupid, like Netscape 4.76 can result in getting a returned page that is significantly easier to deal with than whatever the default is. I think that even in one case I was able to get a page without java script in it by just claiming to be "stupid". I'm sure the web developers had to code that as a special case, but evidently they did.

Anyway some experimentation with claiming to be different browser types can sometimes produce interesting results. Of course this is completely site dependent. If you have the wrong level of browser for a site, usually you get a message saying that rather than a 404 (i.e. it will say something rather than remaining silent). Here's how to claim to be "stupid":

$ua->agent("Mozilla/4.76 [en] (Windows NT 5.0; U)");

In reply to Re^2: how to troubleshoot a http::request 404 problem by Marshall
in thread how to troubleshoot a http::request 404 problem by lexthoonen

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.