optimzing document viewer for wordpress