Safari saving PDF files with a numeric number instead of actual product name

Hi There,


I have two issues I can't figure out as a Front-End Web Developer.

The PDF files work as normal on Edge, Internet Explorer, Chrome, and Firefox.


Issue 1

We have a Macbook Air with Safari version 14.0.2 and when I navigate to our website and try to download a PDF file, it will save it as a numeric number and not the actual PDF name. I have even added the Download attribute in the HTML to force the browser to take that name, but it does not work. On the Macbook Air, it will open the PDF.


Issue 2

We have an IPad 9 with software version 14.4 and when I download and try to open the PDF, it won't open at all. I have downloaded Google Chrome and when I download the PDF, I get a "Chrome can't handle this link" error.


I have posted my question with pictures on Stackoverflow: https://stackoverflow.com/questions/66527053/safari-browser-is-saving-pdf-files-as-numeric-numbers-and-not-the-actual-pdf-nam


Here is the website URL and click on the Documents tab for the PDF links: https://www.parrot.co.za/product/sku/twb-7519a


Downloading PDF's with numbers as the filename.


Element Inspection with Downloads attribute in link:


Chrome Error on IPAD:



Posted on Mar 8, 2021 1:31 AM

Reply
Question marked as Top-ranking reply

Posted on Mar 8, 2021 6:43 AM

I think I have found the answer.


I have used a website to check the Response Headers and discovered that the closing quotation mark on the Filename section of the octet stream is not escaped properly. This is strange as all other browsers did not give any issues until we tested the links on an iPad or MacBook Air.


Similar questions

2 replies
Question marked as Top-ranking reply

Mar 8, 2021 6:43 AM in response to Tig7r

I think I have found the answer.


I have used a website to check the Response Headers and discovered that the closing quotation mark on the Filename section of the octet stream is not escaped properly. This is strange as all other browsers did not give any issues until we tested the links on an iPad or MacBook Air.


Mar 8, 2021 2:36 AM in response to Tig7r

Hi, I think I have narrowed down the issue. A normal PDF link on the same server would download perfectly, but when we use a REST link (File stream) to download the PDF file from another server from a BLOB in a database, this issue occurs. I think it could perhaps be a Mime Type or Meta information issue?

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Safari saving PDF files with a numeric number instead of actual product name

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.