What are the potential drawbacks of attempting to display both a PDF and HTML content at the same time in PHP?

Displaying both PDF and HTML content simultaneously in PHP can be challenging due to the different content types and rendering methods. One potential drawback is that the PDF content may not be displayed correctly in all browsers or devices, leading to a poor user experience. To address this issue, one solution is to provide a download link for the PDF file instead of embedding it directly on the page.

<?php
// Code to display HTML content
echo "<h1>Welcome to our website!</h1>";
echo "<p>This is some HTML content.</p>";

// Code to provide a download link for the PDF file
$pdfFilePath = 'path/to/your/file.pdf';
echo "<a href='$pdfFilePath' download>Download PDF</a>";
?>