• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

PDF Embed API - File Preview Not Available

New Here ,
Jan 20, 2021 Jan 20, 2021

Copy link to clipboard

Copied

Greetings! 

I am having trouble getting the PDF embed API to work on my site. I keep encountering the message "File Preview Not Available" with any PDF file I try. The domain is a test site I created with Weebly https://corporatesampleintranetpage.weebly.com/.

The code I am using is: 

 

<div id="adobe-dc-view"></div>
<script src="https://documentcloud.adobe.com/view-sdk/main.js"></script>
<script type="text/javascript">
document.addEventListener("adobe_dc_view_sdk.ready", function(){
var adobeDCView = new AdobeDC.View({clientId: "<98a6ee14c3d64f3a8eae67ddf3534fc1>", divId: "adobe-dc-view"});
adobeDCView.previewFile({
content:{location: {url: "https://documentcloud.adobe.com/link/documents/files/sample.pdf"}},
metaData:{fileName: "ACORD.pdf"}
}, {});
});
</script>

 

betho95581631_0-1611185588056.png

 

Any and all help is VERY MUCH APPRECIATED! 

Beth

Views

995

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jan 21, 2021 Jan 21, 2021

Copy link to clipboard

Copied

The URL you are pointing to is not a direct link to a PDF. It is a link to a view of the PDF file stored in Document Cloud. At the time of this writing, there is no method of accessing the bytes of a PDF or creating a direct link to a PDF stored in Adobe Document Cloud. You'll need to host your PDF file somewhere else.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Mar 15, 2021 Mar 15, 2021

Copy link to clipboard

Copied

LATEST

Beth you have enclosed your client ID in < > 

 

<98a6ee14c3d64f3a8eae67ddf3534fc1>

 

It should be without the < >, like this:

 

98a6ee14c3d64f3a8eae67ddf3534fc1

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources