fixed footer and policy
This commit is contained in:
@@ -737,7 +737,81 @@ $html .= '</tbody></table>';
|
||||
|
||||
|
||||
//photos da fare
|
||||
$photoRows = '';
|
||||
$hasPhotos = false;
|
||||
|
||||
// Check for photocover
|
||||
if (!empty($photocover)) {
|
||||
$coverPath = $base_url . "uploadimages/" . htmlspecialchars($photocover);
|
||||
$localCoverPath = $_SERVER['DOCUMENT_ROOT'] . "/modulo_certificazione/public/uploadimages/" . htmlspecialchars($photocover);
|
||||
if (file_exists($localCoverPath)) {
|
||||
$imageData = base64_encode(file_get_contents($localCoverPath));
|
||||
$mimeType = mime_content_type($localCoverPath);
|
||||
$photoRows .= <<<HTML
|
||||
<tr>
|
||||
<td class="first-column">Foto Articolo / Article Photo</td>
|
||||
<td class="header-data">
|
||||
<img src='data:$mimeType;base64,$imageData' alt='Cover Photo' style='max-height: 200px;'>
|
||||
</td>
|
||||
</tr>
|
||||
HTML;
|
||||
$hasPhotos = true;
|
||||
}
|
||||
}
|
||||
|
||||
// Check for photoone
|
||||
if (!empty($photoone)) {
|
||||
$photoOnePath = $base_url . "uploaddocuments/" . htmlspecialchars($photoone);
|
||||
$localPhotoOnePath = $_SERVER['DOCUMENT_ROOT'] . "/modulo_certificazione/public/uploaddocuments/" . htmlspecialchars($photoone);
|
||||
if (file_exists($localPhotoOnePath)) {
|
||||
$imageData = base64_encode(file_get_contents($localPhotoOnePath));
|
||||
$mimeType = mime_content_type($localPhotoOnePath);
|
||||
$photoRows .= <<<HTML
|
||||
<tr>
|
||||
<td class="first-column">Foto 1 / Photo 1</td>
|
||||
<td class="header-data">
|
||||
<img src='data:$mimeType;base64,$imageData' alt='Photo 1' style='max-height: 200px;'>
|
||||
</td>
|
||||
</tr>
|
||||
HTML;
|
||||
$hasPhotos = true;
|
||||
}
|
||||
}
|
||||
|
||||
// Check for phototwo
|
||||
if (!empty($phototwo)) {
|
||||
$photoTwoPath = $base_url . "uploaddocuments/" . htmlspecialchars($phototwo);
|
||||
$localPhotoTwoPath = $_SERVER['DOCUMENT_ROOT'] . "/modulo_certificazione/public/uploaddocuments/" . htmlspecialchars($phototwo);
|
||||
if (file_exists($localPhotoTwoPath)) {
|
||||
$imageData = base64_encode(file_get_contents($localPhotoTwoPath));
|
||||
$mimeType = mime_content_type($localPhotoTwoPath);
|
||||
$photoRows .= <<<HTML
|
||||
<tr>
|
||||
<td class="first-column">Foto 2 / Photo 2</td>
|
||||
<td class="header-data">
|
||||
<img src='data:$mimeType;base64,$imageData' alt='Photo 2' style='max-height: 200px;'>
|
||||
</td>
|
||||
</tr>
|
||||
HTML;
|
||||
$hasPhotos = true;
|
||||
}
|
||||
}
|
||||
|
||||
// Add the table only if there are photos
|
||||
if ($hasPhotos) {
|
||||
$html .= <<<HTML
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th colspan="2">FOTO DEL PRODOTTO / PRODUCT PHOTOS</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
$photoRows
|
||||
</tbody>
|
||||
</table>
|
||||
HTML;
|
||||
}
|
||||
|
||||
// virus prot
|
||||
if ($virusprot == "Y") :
|
||||
|
||||
Reference in New Issue
Block a user