7

I want to set header origin when connecting to some url that not owned by me

is it possible to set server [HTTP_ORIGIN] via CURL

curl_setopt($ch,CURLOPT_HTTPHEADER,array('Origin: somevalue'));

1 Answer 1

5

Yes, that will work.

Keep in mind - if setting custom HTTP headers, you must set them all at the same time.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.