我在我的脚本中使用此API(https://api.ssactivewear.com/v2/products/):
ini_set('memory_limit', "300M");
$uri=$end_url.$method;
$ch = curl_init($uri);
$access_key=base64_encode($customer_number.':'.$api_key);
curl_setopt( $ch, CURLOPT_HTTPHEADER, array( 'Authorization: Basic ' . $access_key ) );
curl_setopt($ch, CURLOPT_RETURNTRANSFER ,1);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
$retrive_response = curl_exec($ch);
curl_close($ch);
return $retrive_response;
几次执行脚本后我收到了错误
致命错误:允许的内存大小耗尽314572800字节(尝试分配161956814字节)