php - APNS push notifications not being sent and not gettign any errro

one text

here is my code

    $prefix = "";
$url_apns = 'ssl://gateway.sandbox.push.apple.com:2195';
if ($APP_MODE_NOTIFICATION == "Production") {
    $prefix = "PRO_";
    $url_apns = 'ssl://gateway.push.apple.com:2195';
}



if ($PassengerToDriver == 1) {
    //$name = $generalobj->getConfigurations("configurations", $prefix . "PARTNER_APP_IPHONE_PEM_FILE_NAME");   // send notification to driver
    $name1 = $prefix . "PARTNER_APP_IPHONE_PEM_FILE_NAME";
    $name = $$name1;
} else if ($PassengerToDriver == 2) {
    //$name = $generalobj->getConfigurations("configurations", $prefix . "COMPANY_APP_IPHONE_PEM_FILE_NAME");   // send notification to company
    $name1 = $prefix . "COMPANY_APP_IPHONE_PEM_FILE_NAME";
    $name = $$name1;
} else {
    //$name = $generalobj->getConfigurations("configurations", $prefix . "PASSENGER_APP_IPHONE_PEM_FILE_NAME"); // send notification to passenger
    $name1 = $prefix . "PASSENGER_APP_IPHONE_PEM_FILE_NAME";
    $name = $$name1;
}


$ctx = stream_context_create();

if ($fromDepart == 'admin') {
    $name = '../' . $name;
}

stream_context_set_option($ctx, 'ssl', 'local_cert', $name);

stream_context_set_option($ctx, 'ssl', 'passphrase', $passphrase);
   
$fp = stream_socket_client($url_apns, $err, $errstr, 60, STREAM_CLIENT_CONNECT | STREAM_CLIENT_PERSISTENT, $ctx);

the dd of $fp shows this error

resource(69) of type (persistent stream)

the notification is not sending from server side, can any one help out with this?

Source