Menu

Bad Request

Help
mark
2004-07-22
2004-08-05
  • mark

    mark - 2004-07-22

    hello,

    i am getting the status "HTTP/1.1 400 Bad Request"
    what does this mean?
    how could i avoid this?

     
    • Uwe Hunfeld

      Uwe Hunfeld - 2004-07-28

      Hello !

      Could you pls explain WHEN exactly you get this status ?
      What did you do?
      Did you use the example-script included in the package?
      Which URL did you want to crawl?

       
    • mark

      mark - 2004-08-03

      i changed $crawler in the original example.php to:

      $crawler->setURL("http://nuernberg.gelbeseiten-regional.de/yp/quickSearch.yp?subject=Schreiner&location=Berlin");

      when i'm running example.php the following lines will appear:

      --- snipp ---
      Page requested: http://nuernberg.gelbeseiten-regional.de/yp/quickSearch.yp?subject=Schreiner&location=Berlin
      Status: HTTP/1.1 400 Bad Request

      Referer-page:
      Content received: 439 bytes
      Summery:
      Links followed: 1
      Files received: 1
      Bytes received: 603
      --- snipp ---

      other sites with parameters in the url will work fine, e.g:$crawler->setURL("http://www.hotscripts.com/cgi-bin/search.cgi?bool=AND&query=crawl&catid=2");

      thanx for help - mark

       
      • Uwe Hunfeld

        Uwe Hunfeld - 2004-08-05

        Hi Mark again.

        You defenately found a bug in phpcrawl there.

        The crawler sends an empty "Cookie:" line with the request-header if theres no cookie to send.
        I didnt see a webserver so far that cared about,
        but the server of  http://nuernberg.gelbeseiten-regional.de/ does and returns a "bad request"-header.

        Without the "Cookie:"-line everything works fine with that site, i just tried.

        I will fix that today or tomorrow i guess (not much work) and upload the patched version here.

        I hope thats okay for you,
        and thank you for your "report",

        Greetings,
        huni.

         

Anonymous
Anonymous

Add attachments
Cancel





Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.