2 Summary: Store pages as XML files
4 Prerequisites: Requires at least PmWiki version: 2.2.0; last tested on PmWiki version: 2.2.45
6 Maintainer: [[~Anomen]]
7 Categories: [[!Administration]], [[!CustomPageStore]]
8 Users: {{$FullName}-Users$Rating2} ([[{$FullName}-Users|View]] / [[{$FullName}-Users?action=edit|Edit]])
9 Discussion: [[{$Name}-Talk]]
11 !! Questions answered by this recipe
15 * pages easily editable in plain text editor
16 * better handled by versioning systems (text is no longer single long line)
17 * export/import pages using various tools with XML support
21 The Attach:XMLPageStore.php script stores pmwiki pages into xml files in the ''wiki.d/'' directory.
25 To use this script, simply place it in your ''cookbook'' directory
26 and add the following lines to ''local/config.php'':
29 $EnablePageStoreXML = 1;
30 include_once('cookbook/XMLPageStore.php');
31 $WikiDir = new XMLPageStore('wiki.d/{$FullName}');
34 There's no need to convert or modify your existing pages;
35 ''xmlpagestore.php'' can read existing pages without any difficulty.
36 As pages are edited and saved, they will be then saved as XML files in ''wiki.d/''.
37 Please make sure the above cookbook script is loaded before other scripts.
39 If you want to convert all of your files at once append the following line to local/config.php:
47 Use @@$EnablePageStoreXML@@ variable to enable/disable writing xml files.
56 !! Change log / Release notes
57 * 2011-04-22 - added to PmWiki Cookbook
58 * 2011-09-15 - minor fixes
59 * 2012-12-27 - added support for converting all pages
63 : git repo : http://repo.or.cz/w/anomen-overlay.git/tree/HEAD:/www-apps/pmwiki/cookbook/XMLPageStore
67 * [[~Anomen]] - original script
71 See discussion at [[{$Name}-Talk]]