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

File Preview Not Available. Domain Not Authorized

New Here ,
Jun 03, 2020 Jun 03, 2020

Copy link to clipboard

Copied

I successfully integrated on one site I manage for work with no issues, however on the other site I manage in a volunteer role I'm seeing the issue that the "File Preview is Not Available. This application domain (http://phadp.org) is not authorized to use the provided View SDK Client ID."

 

I've double checked the key and the domain I used when registering, but I cannot figure out why I continue to get this message.

 

Malkayah_0-1591206812286.png

http://phadp.org/?q=node/832

 

Any help would be appreciated. 

Views

4.4K

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
Adobe Employee ,
Jun 03, 2020 Jun 03, 2020

Copy link to clipboard

Copied

Hi Malkayah, Thanks for using View SDK, It is because you whitelisted API Key for domain www.phadp.org but you are trying to access your website by phadp.org domain.  


http://www.phadp.org/?q=node/832 This is working.

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 ,
Jun 03, 2020 Jun 03, 2020

Copy link to clipboard

Copied

Thanks for the reply. Is there a way to add both variations of the domain to the whitelist? Obviously I have no control over how end users chose to visit the domain.

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
Adobe Employee ,
Jun 03, 2020 Jun 03, 2020

Copy link to clipboard

Copied

Please create the API key for "phadp.org" then it should work for both variations of the domain. Thanks.

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 ,
Jun 03, 2020 Jun 03, 2020

Copy link to clipboard

Copied

I did as suggested, and it works for "phadp.org" but when I manually type "www.phadp.org" I get a different file preview error. This one does not saw it is not authorized, but says, "Please reload to try again". Reloading does nothing.

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
Adobe Employee ,
Jun 03, 2020 Jun 03, 2020

Copy link to clipboard

Copied

Issues is occurring because of Cross-origin resource sharing (CORS) which says webpage and file location URL needs to be on the same domain. Example: webpage: https://example.com/viewer/test.html; PDF location: https://example.com/resources/abc.pdf)

In your case, it looks like you are passing the PDF URL as http://phadp.org/files/owoh/owoh24_2.pdfif you pass the File location URL relative to your domain like "/files/owoh/owoh24_2.pdf", then it should work in both cases.

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 ,
Jun 04, 2020 Jun 04, 2020

Copy link to clipboard

Copied

That did the trick. Thanks!

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
Community Beginner ,
Apr 10, 2021 Apr 10, 2021

Copy link to clipboard

Copied

Hello,

 

Can someone help me? I'm also facing the same problem.

I created a credential ID for my domain www.roundstudy.com using this Link

and then created a html code on live demo https://www.adobe.com/go/dcviewsdk_demo for my pdf that I uploaded from my local folder. I pasted that code on my iFrame 

 

HTML Code: <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: "9f1b28edec7b42fcb3581a1a501373d9", divId: "adobe-dc-view"});
adobeDCView.previewFile({
content:{promise: "<FILE_BLOB_PROMISE>"},
metaData:{fileName: "<FILE_NAME>"}
}, {});
});
</script> 

 

credit id: 9f1b28edec7b42fcb3581a1a501373d9

Domain name: www.roundstudy.com.

 

but when I upload the code on my website there is an error: "File Preview is Not Available. This application domain (xxxxxxxxxxxxxxx) is not authorized to use the provided View SDK Client ID."

 

Am I following the right process? Could someone guide me through it

 

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
Community Beginner ,
Apr 10, 2021 Apr 10, 2021

Copy link to clipboard

Copied

Hi there, could you be more specific on where are you locating the pdf file, and in which url are embeding the script?

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
Community Beginner ,
Apr 10, 2021 Apr 10, 2021

Copy link to clipboard

Copied

I've located the file in my local drive. I don't know how to get the source url for the file. The url where I'm embeding the script is roundstudy.com

 

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
Community Beginner ,
Apr 10, 2021 Apr 10, 2021

Copy link to clipboard

Copied

Thats the problem, the pdf file should be on your website, or in any other site that you could host the pdf file. Also the url should be a direct link, that means that the pdf file will begin to download as soon as the moment you access to that url. 

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
Community Beginner ,
Apr 10, 2021 Apr 10, 2021

Copy link to clipboard

Copied

Thank you @German5FFC for the help. Could you suggest me some site where I can keep my pdf and use the link. I was thinking of using Mega where I can upload all my files and use the link as pdf source. Could you also confirm if the steps I'm following are they correct? 

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
Community Beginner ,
Apr 11, 2021 Apr 11, 2021

Copy link to clipboard

Copied

Dropbox, Google Drive are good options too. Keep in mind that there are limits on how many people can access that file. And do not forget the difference between a direct link and a link to a file. For example

link to a file: https://www.dropbox.com/s/3epmnxwhrnk7lgd/Bodea%20Brochure.pdf?dl=0

direct link: https://dl.dropboxusercontent.com/s/3epmnxwhrnk7lgd/Bodea%20Brochure.pdf

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
Community Beginner ,
Apr 11, 2021 Apr 11, 2021

Copy link to clipboard

Copied

Google drive is a better option which link should I be using as source link (Link to file / direct link). Is this code correct ?

<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: "9f1b28edec7b42fcb3581a1a501373d9", divId: "adobe-dc-view"});
adobeDCView.previewFile({
content:{promise: "<FILE_BLOB_PROMISE>"},
metaData:{fileName: "<FILE_NAME>"}
}, {});
});
</script>

 

Do different webpages require differnt clinet id

e.g. if I have Client Id a3463456 for a domain name ww.roundstudy.com can i use the same client ID for 

 www.roundstudy.com/faq ?

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
Community Beginner ,
Apr 11, 2021 Apr 11, 2021

Copy link to clipboard

Copied

The code is ok.
And no, the client id is the same for every page of your domain.

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
Community Beginner ,
Apr 11, 2021 Apr 11, 2021

Copy link to clipboard

Copied

Thank you very much @German5FFC . I'll try this and see if it works.

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
Community Beginner ,
Apr 25, 2021 Apr 25, 2021

Copy link to clipboard

Copied

Hi @German5FFC 

 

I'm still facing the same issue. When i load the code in my iframe this error appears

vipul0D4D_0-1619334213143.png

The code I use 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: "9f1b28edec7b42fcb3581a1a501373d9", divId: "adobe-dc-view"});
		adobeDCView.previewFile({
			content:{location: {url: "https://dl.dropboxusercontent.com/s/u9dmuz8dx5jtddr/Visning%20af%20PDF%20i%20MB%2001.pdf"}},
			metaData:{fileName: "Visning af PDF i MB 01.pdf"}
		}, {});
	});
</script>

I'm using dropbox for my pdf location and the direct link is "https://dl.dropboxusercontent.com/s/u9dmuz8dx5jtddr/Visning%20af%20PDF%20i%20MB%2001.pdf"

My domain name is "www.roundstudy.com".

 

Please help

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
Community Beginner ,
Apr 25, 2021 Apr 25, 2021

Copy link to clipboard

Copied

Try to register the domain that the error is showing

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
Community Beginner ,
Apr 25, 2021 Apr 25, 2021

Copy link to clipboard

Copied

I tried it and it's working now thank you very much ☺️☺️☺️ @German5FFC 

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
Community Beginner ,
Apr 25, 2021 Apr 25, 2021

Copy link to clipboard

Copied

😄

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
Community Beginner ,
May 03, 2021 May 03, 2021

Copy link to clipboard

Copied

@German5FFC 

 

How can we disable commenting in the annotation feature

vipul0D4D_0-1620051897776.png

 

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
Community Beginner ,
May 03, 2021 May 03, 2021

Copy link to clipboard

Copied

You should set showAnnotationTools on false.

For example:

var adobeDCView = new AdobeDC.View({clientId: "blablabla1", divId: adobe-dc-view});
adobeDCView.previewFile({
content:{location: {url: url}},
metaData:{fileName: name}
}, {embedMode: "FULL_WINDOW", showAnnotationTools: false});

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
Community Beginner ,
May 03, 2021 May 03, 2021

Copy link to clipboard

Copied

@German5FFC  But I want require the highlight pen option but not the commnet feature

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
LEGEND ,
May 03, 2021 May 03, 2021

Copy link to clipboard

Copied

Highlights are comments. They are one of the many comment types available in PDF.

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
Community Beginner ,
May 03, 2021 May 03, 2021

Copy link to clipboard

Copied

Im not really sure if you can, I strongly advise you to check the documentation. If you are desperate, you can hide them with css. Every button you see has an id (stickyNote, highlight, freehandTool, etc). 

 

German5FFC_0-1620101520226.png

 

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