fix some issu

This commit is contained in:
2026-08-26 21:47:09 +03:30
parent 74cc50149f
commit 40b185187c
14 changed files with 179 additions and 72 deletions
@@ -29,7 +29,7 @@ class MeliPayamakProvider implements SmsProviderInterface
];
$handle = curl_init('https://rest.payamak-panel.com/api/SendSMS/SendSMS');
curl_setopt_array($handle, [
$opts = [
CURLOPT_HTTPHEADER => ['content-type: application/x-www-form-urlencoded'],
CURLOPT_RETURNTRANSFER => true,
CURLOPT_SSL_VERIFYHOST => false,
@@ -37,7 +37,16 @@ class MeliPayamakProvider implements SmsProviderInterface
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => http_build_query($data),
CURLOPT_TIMEOUT => 30,
]);
CURLOPT_CONNECTTIMEOUT => 5,
CURLOPT_PROXY => '',
];
if (defined('CURLOPT_IPRESOLVE') && defined('CURL_IPRESOLVE_V4')) {
$opts[CURLOPT_IPRESOLVE] = CURL_IPRESOLVE_V4;
}
if (defined('CURLOPT_HTTP_VERSION') && defined('CURL_HTTP_VERSION_1_1')) {
$opts[CURLOPT_HTTP_VERSION] = CURL_HTTP_VERSION_1_1;
}
curl_setopt_array($handle, $opts);
$response = curl_exec($handle);
$error = curl_error($handle);