User:Zzmonty/import2

From MediaWiki.org
Jump to: navigation, search


MediaWiki extensions manual - list
Crystal Clear action run.png
Import2

Release status: experimental

Implementation API
Description Replacement for "import.php" include file.
Author(s) Melissa Newman (zzmontyTalk)
Last version 0.1 (2009-12-08)
MediaWiki 1.15.1
PHP 5.0.0
License Creative Commons Share Alike
Download No link
User:zzmonty/import2/readme.txt
User:zzmonty/import2/changelog.txt
Added rights

import

Contents

[edit] What can this extension do?

Replacement for the "/include/import.php" file. Import2 does the following improvements to the standard import file:

  • General cleanup of import.php file to make it easier to maintenance in the future.
  • Processes all variables in the XML dump file including the siteinfo variables.
  • The sitename and base are used to establish links back to original import page.
  • Template:ImportBot has the example text: Note: This page was originally imported from <sitename>, page <title> on Dec 08, 2009. Title is actually a hyperlink to the exact revision imported.
  • Import username (or ip) are changed to <sitename>ImportBot.
  • Import comment is changed to "Imported from <sitename>, article <basename>/index.php?oldid=<revid>". This enables compliance with MediaWiki licensing to state exact version of page imported. The original comment is not as valuable as information to do a full traceback of a page.
  • Page is tagged with an import category, for example, Category:WikipediaImportBot.

[edit] Example

On article page:

Note: This page was originally imported from Wikipedia, page Scooby-Doo on Dec 08, 2009.

On history page:

00:12, December 9, 2003 WikipediaImportBot (block) m (24 bytes) (Imported from Wikipedia, http://en.wikipedia.org/wiki/index.php?oldid=329763663)

[edit] Usage

Not applicable. This is a library include file that works behind the scenes during import from Special:import or maintenance/importDump.php. Once the extension is installed, there is nothing else to do.

[edit] Installation

  1. Replace the "import.php" file in the $src/includes.
  2. Create the page template:ImportBot on your Wiki.
  3. Create user pages, for example, User:WikipediaImportBot.
  4. Create category pages, for example, Category:WikipediaImportBot.

[edit] Configuration parameters

Not applicable.

[edit] User rights

This extension is only valid if the user has import rights.

[edit] Code

import.php
Template:ImportBot (MediaWiki template)

[edit] See also

Not applicable.

Personal tools
Namespaces

Variants
Actions
Navigation
Support
Download
Development
Communication
Print/export
Toolbox