I did everything in https://drupal.org/node/1515868.
Then I added field with PDF.
Choosed "PDF default" view.
I can't see PDF but can see:

[an error occurred while processing this directive]

error screen
http://screencast.com/t/znXk87k360c2

Comments

a.milkovsky’s picture

Status: Active » Needs review
Issue tags: +PDF
StatusFileSize
new667 bytes

I've fixed it.
This issue inspired me https://github.com/mozilla/pdf.js/issues/2371?source=cc.

Issue was in iframe src. As written at pdf.js page we must "grab files from the build/generic folder".
So the iframe src link to "/build/generic/web/viewer.html" instead of "/web/viewer.html".
See the attached patch.

P.S. It seems you are still working in the master branch. For information on how to change that click here.

I've used 7.x-1.x branch

shenzhuxi’s picture

Have you tried 7.x-1.x-dev? I can't reproduce this bug.
About the patch, the default viewer should be used without "node make generic".

a.milkovsky’s picture

I tried dev also.

About the patch, the default viewer should be used without "node make generic".

hm. doesn't work without "node make generic"

a.milkovsky’s picture

I checked.
Works without "node make generic" only on live server. localy doesn't work :(
Can you suggest what is the issue can be?

shenzhuxi’s picture

Maybe open the browser console to check local JS. Seems your browser can't access some JS/CSS files. It may be because of your local dev environment settings.

a.milkovsky’s picture

no errors in js console.
But all files in build folder work fine...

a.milkovsky’s picture

Maybe you use content of /build/generic/ folder? I tried use only files in /build/generic/ and it worked without patching

shenzhuxi’s picture

Issue summary: View changes
Status: Needs review » Closed (cannot reproduce)