How can I set a language header for my cURL request? e.g. now I get the homepage of facebook.com in dutch, probably because my server is in the Netherlands / default language send by headers?..
I prefer english before dutch in this case so I tried to set an httpheader in curl but I make no sense? What do I do wrong or what should I have to set?
(zend notation)
CURLOPT_HTTPHEADER => 'Accept-Language: en-US;q=0.6,en;q=0.4',
Thanks in advance!
I arrived at this page looking for a way to pass the language header to curl at the command line. If you want to set headers in a bash one-liner, use
-H Accept-Language
You have to add a header option in your request.
You will have something like this:
All you have to do is add this line to your $options array: