How to use PHP to execute 'Add' method

This command works in the linux shell:

curl “https://ipfs.infura.io:5001/api/v0/add
-u “PROJECT_ID:PROJECT_SECRET”
-X POST
-H “Content-Type: multipart/form-data”
-F file=@“test_IPFS_data.htm”

The following PHP code displays “file argument ‘path’ is required”:

$curl = curl_init();
curl_setopt($curl, CURLOPT_URL,“https://ipfs.infura.io:5001/api/v0/add”);
curl_setopt($curl, CURLOPT_POST, 1);
$sTemp = urlencode(“test_IPFS_data.htm”);
curl_setopt($curl, CURLOPT_POSTFIELDS, “file=$sTemp”);
curl_setopt($curl, CURLOPT_USERPWD, “PROJECT_ID:PROJECT_SECRET”);
curl_exec($curl);
curl_close($curl);

When I add the next two lines, I get this error: “no multipart boundary param in Content-Type #”.

$headers = array(‘Content-type: multipart/form-data’);
curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);