0

Have set the forcedownload to "true" -

<mediaType name="PDF file" extensions="pdf">
<mimeType>application/pdf</mimeType>
<forceDownload>true</forceDownload>
<sharedTemplate>system/media/unversioned/pdf</sharedTemplate>
<versionedTemplate>system/media/versioned/pdf</versionedTemplate>
</mediaType>

Have commented the mimetype line-

<!-- 
  <mediaType extensions="pdf"><mimeType>application/pdf</mimeType></mediaType>
   -->

But still the pdf file is opening in the tab , this is happening only on production site and not on other env , Can someone please help

4
  • are you getting any errors in log? Commented Nov 22, 2022 at 13:31
  • Can you confirm that your patch is being applied using showconfig.aspx? Commented Nov 22, 2022 at 13:43
  • 1
    Have you checked out this? sitecore.stackexchange.com/questions/6046/… Commented Nov 22, 2022 at 14:02
  • How is the download being triggered? Link in the UI? Direct viewing of a specific URL? Or do you want this to apply across the board no matter what? If UI, try adding a download attribute to the <a>. Commented Nov 22, 2022 at 14:08

0

Browse other questions tagged or ask your own question.