Copy link to clipboard
Copied
Copy link to clipboard
Copied
Can you share your code? The dialog doesn't provide enough information to diagnose the issue.
Copy link to clipboard
Copied
Hi find the below code. This was working fine some days back, There is no change since it was working.
$.getScript("https://documentcloud.adobe.com/view-sdk/main.js", function () {
var viewerConfig = {
showAnnotationTools: false,
enableFormFilling: false,
showLeftHandPanel: true,
showDownloadPDF: true,
showPrintPDF: true,
showPageControls: true,
dockPageControls: true,
defaultViewMode: "", /* Allowed possible values are "FIT_PAGE", "FIT_WIDTH" or "". */
};
var ids = {
"st-prev-www.gepower.com": "61d3e4e8c8414c18ab503e069393145b",
"st-gaspower.portal.ge.com": "fabf91fe9c9343bb92f9b12ce4dc0cdc",
"prev-www.gepower.com": "372b3ea823ba48ad9f15518d428b9a38",
"gaspower.portal.ge.com": "815531dec4ea49839d7d45e5b8b7e3c4"
};
/* Wait for Adobe Document Cloud View SDK to be ready */
document.addEventListener("adobe_dc_view_sdk.ready", function () {
/* Initialize the AdobeDC View object */
var adobeDCView = new AdobeDC.View({
/* Pass your registered client id */
clientId: ids[location.hostname],
/* Pass the div id in which PDF should be rendered */
divId: "pdf_modal",
});
/* Invoke the file preview API on Adobe DC View object */
adobeDCView.previewFile({
/* Pass information on how to access the file */
content: {
/* Location of file where it is hosted */
location: {
url: $('.pdf_btn').data('pdfpath'),
},
},
/* Pass meta data of file */
metaData: {
/* file name */
fileName: $('.pdf_name').data('pdfname')
}
}, viewerConfig);
});
});
Copy link to clipboard
Copied
Ok - What's the URL to the PDF?
Copy link to clipboard
Copied
Hi
The PDF url is https://st-gaspower.portal.ge.com/content/dam/power_portal/global/en_US/documents/news/news_imported...
This is sso protected url.
But surprising this is coming today. But Yesterday this was not coming and also the same issue was there in other site.
Copy link to clipboard
Copied
Are you sure that's a direct link to a PDF file?
Copy link to clipboard
Copied
Hi
It did wrok for sometime and then from yesterday its onwards its giving same error.
Subhendu
Copy link to clipboard
Copied
Hi
I figured out there some special charecters which was causing this error.
Thanks a lot for the help. Really appriciated.
Subhendu