HandleMSWord
Questions answered by this recipe
Ever wanted to view your wiki page in the world's most popular word processor, Microsoft (tm) Word? This recipe retrieves just the page text from a PmWiki page, and sends it to a viewer's browser as an MS Word attachment. This has been known to work in MS Word 2003 (please update for other working versions).
Description
This recipe sends the page text as a MS Word document.
Notes
- Download the Attach:HandleMSWord.phpΔ code.
- Place in
or wherever.$FarmD
/cookbook/ - Add
include("
to your site's configuration$FarmD
/cookbook/HandleMSWord.php"); - You may want to update your
Site.PageActions
. The action is 'msword', or "?action=msword".
When Word views the page, CSS classes remain intact (e.g. p.question). This allows you to modify the style for the page in Word.
I strip out all hyperlinks. I will later add in code to make this optional behavior.
Release Notes
0.5 - April 25, 2007 Initial Release. BenWilson April 25, 2007, at 02:19 PM
See Also
Contributors
Comments
See discussion at HandleMSWord-Talk
User notes? : If you use, used or reviewed this recipe, you can add your name. These statistics appear in the Cookbook listings and will help newcomers browsing through the wiki.