Friday, May 10, 2024
 Popular · Latest · Hot · Upcoming
88
rated 0 times [  94] [ 6]  / answers: 1 / hits: 25876  / 11 Years ago, mon, february 25, 2013, 12:00:00

I'm using nodejs and chromium for my desktop app. The problem is that I can't open pdf files in chromium. So I googled and found that most of the answers are related to mozplugger plugin. I installed the plugin as mentioned in the below link:



http://www.tootips.com/2013/01/how-to-open-pdf-files-inside-chromium.html



Now I'm getting an error message : Mozplugger: M4 parsing of config generated error when I try to open pdf file in chromium. How can I resolve this error?



Please help me!


More From » node.js

 Answers
55

In Linux I think we need mozplugger plugin for viewing pdf files. I just removed and installed mozplugger again (Reference links: http://www.tootips.com/2013/01/how-to-open-pdf-files-inside-chromium.html, http://mozplugger.mozdev.org/ ) and now it seems to work.



In windows we need to install a system pdf reader like acrobat (http://www.adobe.com/in/products/reader.html), as chromium downloads and displays pdf with system PDF viewer (Reference link: http://code.google.com/p/chromium/wiki/ChromiumBrowserVsGoogleChrome).



An alternative solution is to open the pdf link in default browser with help of node.js using below script.



Install the node.js open module:



$ npm install open


use:



var open = require('open');
open('http://www.google.com', function (err) {
if (err) throw err;
console.log('The user closed the browser');
});


Reference link: How to use nodejs to open default browser and navigate to a specific URL


[#80018] Saturday, February 23, 2013, 11 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
nikhilh

Total Points: 224
Total Questions: 89
Total Answers: 99

Location: Bahrain
Member since Fri, Sep 16, 2022
2 Years ago
;