From the Knowledgebase

Using Caching or Minifying Plugins

Using WP Super Cache, W3 Total Cache, WP Rocket, Autoptimize, or other plugins to minify and/or cache the scripts running on your site has been known to create issues with the plugin's function. Some themes also provided caching / minifying of JavaScript. The plugin scripts are already minified so you will not be losing any efficiency or load speed by excluding them from these tools.

This error often presents as PDFs failing to load, appearing as a link, or get stuck on loading. To rectify this error, you will need to exclude the following URIs for the plugin scripts from any caching and/or minifying tools:

Free version paths:

  • /wp-content/plugins/pdf-embedder/js/all-pdfemb-basic-4.6.4.min.js
  • /wp-content/plugins/pdf-embedder/js/pdfjs/pdf-4.6.4.min.js
  • /wp-content/plugins/pdf-embedder/js/pdfjs/pdf-4.6.4.worker.min.js

Premium version paths (v5.0.x):

  • /wp-content/plugins/PDFEmbedder-premium/js/all-pdfemb-premium-5.0.2.min.js
  • /wp-content/plugins/PDFEmbedder-premium/js/pdfjs/pdf-5.0.2.min.js
  • /wp-content/plugins/PDFEmbedder-premium/js/pdfjs/pdf-5.0.2.worker.min.js

Premium version paths (v5.1.x):

  • /wp-content/plugins/PDFEmbedder-premium/assets/js/all-pdfemb-premium.js
  • /wp-content/plugins/PDFEmbedder-premium/assets/js/min/pdf-viewer-min.js
  • /wp-content/plugins/PDFEmbedder-premium/assets/js/min/pdf-worker-min.js

Secure version paths (v5.0.x):

  • /wp-content/plugins/PDFEmbedder-premium-secure/js/all-pdfemb-premium-5.0.2.min.js
  • /wp-content/plugins/PDFEmbedder-premium-secure/js/pdfjs/pdf-5.0.2.min.js
  • /wp-content/plugins/PDFEmbedder-premium-secure/js/pdfjs/pdf-5.0.2.worker.min.js

Secure version paths (v5.1.x):

  • /wp-content/plugins/PDFEmbedder-premium-secure/assets/js/pdf-embedder.js
  • /wp-content/plugins/PDFEmbedder-premium-secure/assets/js/pdf-js-viewer.js
  • /wp-content/plugins/PDFEmbedder-premium-secure/assets/js/min/pdf-viewer-min.js
  • /wp-content/plugins/PDFEmbedder-premium-secure/assets/js/min/pdf-worker-min.js

Note: all caching and minifying plugins differ as to where exclusions can be added. Please refer to the caching/minifying plugin's documentation for specific instructions on where and how to add these script paths as these exclusions may be located in "hidden" Advanced settings options. The scripts should be excluded from aggregate / inline caching as well as general JS caching.

Be sure to flush any caches including ones specifically for JS after you exclude the scripts so that they can be loaded by the site again and the embed viewer should be displayed correctly once this has been done.

Top