开发者

Zend Framework: How to redirect as a POST request?

I need to POST data from inside a controller to a third party webs开发者_开发问答ite and make sure they receive my website as the HTTP_REFERER. How can I do this?


The Referer is sent as a header, simply:

$client = new Zend_Http_Client($uri);
$client->setHeaders('Referer', 'http://www.yourwebsite.com/');
$client->request(Zend_Http_Client::POST);


There's no robust way to have the client browser post some data of its own accord with an appropriate HTTP referrer.

You will have to do it from the server, using curl or a similar library.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜