minor reworking of page fetch section

master
Jon Dowland 2009-10-16 11:23:55 +01:00
parent 58287a929b
commit 0bee923470
1 changed files with 4 additions and 1 deletions

View File

@ -53,7 +53,7 @@ Once you have a list of page names, you can fetch the data for each page.
### Method 1: via HTTP and `action=raw` ### Method 1: via HTTP and `action=raw`
You need to create two derived strings from the page titles already: the You need to create two derived strings from the page titles: the
destination path for the page and the source URL. Assuming `$pagename` destination path for the page and the source URL. Assuming `$pagename`
contains a pagename obtained above, and `$wiki` contains the URL to your contains a pagename obtained above, and `$wiki` contains the URL to your
mediawiki's `index.php` file: mediawiki's `index.php` file:
@ -64,6 +64,9 @@ mediawiki's `index.php` file:
mkdir -p `dirname "$dest"` mkdir -p `dirname "$dest"`
wget -q "$wiki?title=$src&action=raw" -O "$dest" wget -q "$wiki?title=$src&action=raw" -O "$dest"
You may need to add more conversions here depending on the precise page titles
used in your wiki.
### Method 2: via HTTP and `Special:Export` ### Method 2: via HTTP and `Special:Export`
Mediawiki also has a special page `Special:Export` which can be used to obtain Mediawiki also has a special page `Special:Export` which can be used to obtain