could not read pdf file [closed]
adobe reader could not open a.pdf because it is either开发者_开发问答 not a supported file type or because the file has been damaged(for example , it was sent as an email attachment and wasn't correctly decoded) show this error when open downloaded pdf file in php . i used the following code:
header('Content-disposition:attachment;filename=customer_acc_info_form.pdf');
header('Content-type:application/pdf');
readfile('bo_account/customer_acc_info_form.pdf');
<li><a href="customer_acc_info_form.php">Customer Account Information Form</a></li>
You should remove the <li>...</li>
from the PHP file. It's going to be appended at the end of the PDF file (after the readfile call) and cause it to be invalid. Make sure that there is nothing else sent after the file.
精彩评论