joschan21 / quill

Quill - A Modern SaaS-Platform Built With Next.js 13
1.9k stars 513 forks source link

Issue with loading pdf #60

Open Obercasa13 opened 10 months ago

Obercasa13 commented 10 months ago

Hi, i get an error with loading the pdf. the console says:

Failed to load resource: the server responded with a status of 403 (Forbidden) app-index.js:32 Warning: UnexpectedResponseException: Unexpected server response (403) while retrieving PDF "https://uploadthing-prod.s3.us-west-2.amazonaws.com/d14e2e5e-8498-4641-a6bd-553f2459ce98-f1scep.pdf".

! giterror

Obercasa13 commented 10 months ago

anyone ideas to fix that :)?

sanjayio commented 9 months ago

Change these url's back to file.url

ijaspreetsinghh commented 9 months ago

Im facing the same issue,

changing file.url in [FileId]/page.tsx to https://utfs.io/f/${file.key} worked for me. Here full code

In [FileId]/page.tsx, where you are passing url ,do <PdfRenderer url={https://utfs.io/f/${file.key}} />

<PdfRenderer url={https://utfs.io/f/${file.key}} />

PdfRendered

image and on the PdfRenderer simply the url param. Here key look like 2fafdade-aefc-a08-r2lbah.pdf. so the new url becomes https://utfs.io/f/2fafdade-aefc-a08-r2lbah.pdf

Zem-0 commented 6 months ago

can you specify file location