in reply to Anyone know why I can't scrape this page?

I get a file not found page. Are you actually getting the same page that appears in a browser or are you getting the file not found page as well? Can someone print the results?

I'm going to try it later on tonight when I get home.

I wonder if the server was too busy when I tried the first few times. I was running the script when the college football games were going on. Accessing the page with a browser took a while too.

  • Comment on Re: Anyone know why I can't scrape this page?

Replies are listed 'Best First'.
Re^2: Anyone know why I can't scrape this page?
by Lawliet (Curate) on Sep 06, 2008 at 23:20 UTC
    "I get a file not found page."

    Upon closer review, I also get that error. The file that cannot be found is /nfl/odds/las-vegas/line-movement/jets-dolphins.cfm which I find odd seeing as the url in the script is nfl/odds/las-vegas/line-movement/jets-@-dolphins.cfm. (Notice the @ sign between the NFL teams).

    Either escape the alleged array or use single quotes.

    I'm so adjective, I verb nouns!

    chomp; # nom nom nom

      The '@' is followed by an '-' here, which is not allowed as valid identifier.

      So it can't be an array. But to make sure I would use single quotes, too.

      Update: striked that rubbish. See my answer.

        So Perl sees that there is an '@' followed by a '-' and removes that from the string?

        I'm so adjective, I verb nouns!

        chomp; # nom nom nom