2
<!DOCTYPE html>
<html>
<head>
    <title></title>
</head>
<body>
<?php
echo '<img src="img/print.png" /><br>';
echo 'check';
?>
</body>
</html>

I use this code for show the image in the we-browser then I use this code to download the file with .doc format

<!DOCTYPE html>
<html>
<head>
    <title></title>
</head>
<body>
<?php
header("Content-Type: application/vnd.ms-word");
header("Expires: 0");
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header("Content-disposition: attachment; filename=nyoba.doc");
echo '<img src="img/print.png" /><br>';
echo 'check';
?>
</body>
</html>

but the image didn't just box with text image not found or has been remove, what the solution for this problem? Sorry I can speak English very well

Razia sultana
  • 2,168
  • 3
  • 15
  • 20

0 Answers0