0

I have coded a file download button and I want to change the file name when downloaded. The original file name is an ugly concatenation of Ids and is also signe by AWS.

When I use a local file, the downloaded is carried out as wished, with the modified name. But when I use the AWS stored and signed file I still get the real file name. Actually the issue occurs with all external files.

The example below shows the issue. The file should be download as newname.pdf. In my browser (Mac Chrome 67.0.3396.87) it's being downloaded as activities.pdf.

<a href="https://www.ac-strasbourg.fr/fileadmin/pro/Formation_personnels/FOAD/activites.pdf" download="newname.pdf" target="_self">Test button</a>
vonwolf
  • 635
  • 3
  • 10
  • 23

1 Answers1

0

Probably not allowed by External servers: CORS headers.

Related: HTML5 download attribute not working when downloading from another server, even when Access-Control-Allow-Origin is set to all (*)

nixUser
  • 180
  • 1
  • 7