diff --git a/Societes/ebene/Tarifs/Controleur/Editioncarteassure.php b/Societes/ebene/Tarifs/Controleur/Editioncarteassure.php index 813cc202..20c4175e 100755 --- a/Societes/ebene/Tarifs/Controleur/Editioncarteassure.php +++ b/Societes/ebene/Tarifs/Controleur/Editioncarteassure.php @@ -157,7 +157,7 @@ $headers = @get_headers($photoPath); //if($faceRegistered=="1" && file_exists($photoPath)) // if (!empty($assure['lienPhoto']) && $headers && strpos($headers[0], '200')) { -if ($faceRegistered=="1" && !empty($assure['lienPhoto']) && $headers && strpos($headers[0], '200')) { +if (!empty($photo) && $headers && $faceRegistered=="1" && strpos($headers[0], '200')) { $data = decryptImage($photoPath); $data = base64_decode($data); $temp = $_SESSION['lienPhotoFace'].'tmp_'.uniqid().'.jpg'; @@ -165,7 +165,6 @@ if ($faceRegistered=="1" && !empty($assure['lienPhoto']) && $headers && strpos($ // $pdf->Image($photoPath, $photoX, $photoY, 25, 25); $pdf->Image($temp, $photoX, $photoY, 25, 25); // Réduction de 30x30 à 25x25 // unlink($temp); - var_dump($temp); } else { // Cadre pour la photo si non disponible $pdf->Rect($photoX, $photoY, 25, 25); @@ -174,6 +173,16 @@ if ($faceRegistered=="1" && !empty($assure['lienPhoto']) && $headers && strpos($ $pdf->Cell(25, 3, mb_convert_encoding(_('Photo non disponible'), "ISO-8859-1", "UTF-8"), 0, 1, 'C'); } +/* +var_dump( + "faceRegistered" => $faceRegistered, + "photo" => $photo, + "headers" => $headers, + "strpos" => strpos($headers[0], '200'), + "temp" => $temp, +); +*/ + // Nom du souscripteur en bas $pdf->SetFont('Arial', 'B', 6); $pdf->SetXY(0, 49);