部分图像显示,部分图像不显示(坏X)



一些图像显示和一些图像不显示(坏X)代码在下面,我也使用xampp 5 (mpdf)....

if(!empty($row["google_address"])){
$address =  $row["google_address"].'<br>'.'/'.'Lat - '.$row["latitude"].' / '.'Long - '.$row["longitude"];
}else{
$address ='';
}
$table .= '<tr>';
$table .= "<td>".$i++."</td>";
$table .= "<td>".$row["name"]."</td>";
$table .= "<td>".$row["mobile"]."</td>";
$table .= "<td>".$row["organization_name"]."</td>";
$table .= "<td>".$row["beatName"]."</td>";
$table .= "<td>".$row["customer_type"]."</td>";
$table .= "<td>".$i_Type."</td>";
$table .= "<td>".$row["intration_date"]."</td>";
$table .= "<td>".$row["next_activity_at"]."</td>";
$table .= "<td>".$row["call_time"]."</td>";
$table .= "<td>".$row["purpose"]."</td>";
$table .= "<td>".$row["status"]."</td>";
$table .= "<td>".$vIn."</td>";
$table .= "<td>".$vOut."</td>";
$table .= "<td>".$row["remark"]."</td>";
$table .= "<td>".$row["rating"]."</td>";
$table .= "<td>".str_replace('' ', ''', ucwords(str_replace(''', '' ', strtolower($row["fname"]))))."</td>";
$table .= "<td>".$address."</td>";
// $pathe = Yii::getAlias('@web/uploads/crm_images/');
// $img = $row["visit_image"] ? ' <img src = "'.$pathe.$row["visit_image"].'" width ="200px" height = "200px">' : '';

// $img = $remark1[0]['image_one'] ? ' <img src = "https://timekompas.com/backend/web/uploads/task_photo/'.$remark1[0]['image_one'].'" width ="80px" height = "80px">' : '';
$img = $row["visit_image"] ? ' <img src = "https://timekompas.com/backend/web/uploads/crm_images/'.$row["visit_image"].'" width ="200" height = "200">' : '';
//echo $row["visit_image"];
//echo $img;
//die;
$table .="<td>".$img."</td>";

mpdf code (Xampp 5):-

$path = Yii::getAlias("@vendor/MPDF/mpdf.php");
require_once($path);
$mpdf = new mPDF('en-GB-x', 'A4-L', '', '', 5, 5, 5, 5, 6, 3);
// $mpdf->curlAllowUnsafeSslRequests = true;
// $mpdf->showImageErrors = true;
// $mpdf->debug = true;
$mpdf->packTableData = true;
$mpdf->SetDisplayMode('fullpage');
$mpdf->SetFooter('Contact no: +91-771-4700067, 7772800067 Email ID: timekompas@entitcs.com');
$mpdf->list_indent_first_level = 0; // 1 or 0 - whether to indent the first level of a list
// if($_SESSION["isSupAdmin"]=='1')
// {
//  $mpdf->SetWatermarkText('TIME KOMPAS');
//  }
// else
//  {
//   $mpdf->SetWatermarkText('TIME KOMPAS');
// $mpdf->SetWatermarkText($_SESSION["timecampus_officename"]);
if($_SESSION["ofc_new_com"] != '' && $_SESSION["ofc_new_name"] != ''){

$mpdf->SetWatermarkText($_SESSION["ofc_new_com"].'( '.$_SESSION["ofc_new_name"].' )');
}
if(($_SESSION['order_detail'] != '')||($_SESSION['taskreport_sql'] != '')){
$employee =Yii::$app->session->get('empdata');
$office = Yii::$app->db->createCommand("select ofc_name,company_name from master_office where ofc_id = '".$employee['employee']['emp_ofcid']."' ")->queryOne();
$mpdf->SetWatermarkText($office["company_name"].'( '.$office["ofc_name"].' )');
}

//}
/* $table .=$_SESSION['khumesh_map']; */
//$mpdf->SetWatermarkText($_SESSION['ofc_new_com']);

$mpdf->showWatermarkText = true;
$mpdf->watermarkTextAlpha = 0.3;
$mpdf->simpleTables = true;
$mpdf->WriteHTML($table);
$mpdf->Output($filename . '.pdf', 'I');

exit;

问题图像(在我的图像一个图像显示和一个图像显示x和2图像是空白的,因为那个空。)

输入图片描述

我怎样才能解决这个问题

代码没问题,但图像大小有问题,图像大小大于20kb这是一个原因

最新更新