curl and some sites

Discussion in 'PHP' started by commandos, Sep 30, 2006.

  1. #1
    does the php curl function could be disabled in some sites ?

    like google ?

    when i try to get content it dont allow me ...

    any idea ?
     
    commandos, Sep 30, 2006 IP
  2. noppid

    noppid gunnin' for the quota

    Messages:
    4,246
    Likes Received:
    232
    Best Answers:
    0
    Trophy Points:
    135
    #2
    I think it would have to do more with how you told curl to make the call. Like the header sent for instance.
     
    noppid, Sep 30, 2006 IP
  3. commandos

    commandos Notable Member

    Messages:
    3,648
    Likes Received:
    329
    Best Answers:
    0
    Trophy Points:
    280
    #3
    some example :

     
    commandos, Sep 30, 2006 IP
  4. penagate

    penagate Guest

    Messages:
    277
    Likes Received:
    17
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Hi!

    If you have fopen URL wrappers enabled (as by default), use file_get_contents() to get a remote page.

    Regards
    - P
     
    penagate, Sep 30, 2006 IP
  5. DrMalloc

    DrMalloc Peon

    Messages:
    130
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Google blocks the default wget user-agent, and probably the default CURL one too. Try changing the user-agent for the request and see if that makes any difference.
     
    DrMalloc, Oct 2, 2006 IP