Embedded Acrobat Reader in Google Chrome on Ubuntu 9.10
One of the reasons for switching my home PC to ubuntu is so that I can use the Google Chrome Browser. Chrome runs each tab/page in its own thread, and makes better use of my quad-core CPU.
However, there’s a nasty bug in chrome: you can’t view acrobat documents embedded inside the browser (see here). You get a gray screen instead like this:
There are a few workarounds, the easiest being to just use firefox. But that would defeat the whole point.
Another way is to search for and delete all the nppdf.so files on your system. This is the module that lets the browser know how to embed acrobat reader documents inside the browser window itself. With this gone, any PDF files you open will cause acrobat reader to launch in a separate window, where viewing it works fine.
But what if you’re designing a web site where embedded PDFs are part of the whole scheme of things? In that case, you can do this:
- Remove all the nppdf.so files
- Go to the URL “about:plugins” in your browser, there should be no adobe reader plugin listed.
- Execute the following:
apt-get remove mozplugger
apt-get install libx11-dev
tar xzvf mozplugger-1.13.2.tar.gz
- Restart your chrome browser.
Now you get acrobat reader embedded in chrome:
Note: You have to download the latest version of mozplugger, the one in Ubuntu’s repositories won’t do the trick. Hopefully Ubuntu 10.4 (due in 12 days) has a newer mozplugger.
This post was originally published as a Facebook Note at 2010-04-17 04:06:52 +0800.