我在使用此脚本CURLOP时遇到问题

问题描述 投票:0回答:1
curl_setopt($ch, CURLOPT_POSTFIELDS, file_get_contents("php://input"),$POSTFIELDS);

如何将此脚本file_get_contents与POSTFIELDS集成在同一行上

javascript php
1个回答
0
投票

您可以连接数据,使用. "&" . $POSTFIELDS

$POSTFIELDS = "[email protected]&token=1234";
curl_setopt($ch, CURLOPT_POSTFIELDS, file_get_contents("php://input") . "&" . $POSTFIELDS);
© www.soinside.com 2019 - 2024. All rights reserved.