diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2013-01-18 16:46:04 +0100 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2013-01-18 16:46:04 +0100 |
commit | 63601400e476c6cf43d985f3e7b9864681695ed4 (patch) | |
tree | f7846203a952e38aaf66989d0a4702779f549962 /docs | |
parent | 8ff01378c9e0207f9169b81966a51def645b6a51 (diff) |
Update to MediaWiki 1.20.2
this update includes:
* adjusted Arch Linux skin
* updated FluxBBAuthPlugin
* patch for https://bugzilla.wikimedia.org/show_bug.cgi?id=44024
Diffstat (limited to 'docs')
-rw-r--r-- | docs/code-coverage/README | 2 | ||||
-rw-r--r-- | docs/database.txt | 6 | ||||
-rw-r--r-- | docs/distributors.txt | 7 | ||||
-rw-r--r-- | docs/doxygen_first_page.php | 2 | ||||
-rw-r--r-- | docs/export-0.1.xsd | 36 | ||||
-rw-r--r-- | docs/export-0.2.xsd | 48 | ||||
-rw-r--r-- | docs/export-0.3.xsd | 68 | ||||
-rw-r--r-- | docs/export-0.4.xsd | 76 | ||||
-rw-r--r-- | docs/export-0.5.xsd | 78 | ||||
-rw-r--r-- | docs/export-0.6.xsd | 84 | ||||
-rw-r--r-- | docs/export-0.7.xsd | 272 | ||||
-rw-r--r-- | docs/export-demo.xml | 269 | ||||
-rw-r--r-- | docs/hooks.txt | 153 | ||||
-rw-r--r-- | docs/language.txt | 20 | ||||
-rw-r--r-- | docs/magicword.txt | 4 | ||||
-rw-r--r-- | docs/memcached.txt | 2 | ||||
-rw-r--r-- | docs/uidesign/mediawiki.action.history.diff.html | 12 |
17 files changed, 765 insertions, 374 deletions
diff --git a/docs/code-coverage/README b/docs/code-coverage/README index 7bc55ce2..76ce9bdc 100644 --- a/docs/code-coverage/README +++ b/docs/code-coverage/README @@ -1,2 +1,2 @@ This directory is for the auto-generated phpunit code coverage. -Run 'make coverage' in the maintenance/tests/phpunit subdirectory to build. +Run 'make coverage' in the tests/phpunit subdirectory to build. diff --git a/docs/database.txt b/docs/database.txt index 3985b70e..c0a2412c 100644 --- a/docs/database.txt +++ b/docs/database.txt @@ -8,7 +8,7 @@ By Tim Starling, January 2006. For information about the MediaWiki database layout, such as a description of the tables and their contents, please see: http://www.mediawiki.org/wiki/Manual:Database_layout - http://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/maintenance/tables.sql?view=markup + https://gerrit.wikimedia.org/r/gitweb?p=mediawiki/core.git;a=blob_plain;f=maintenance/tables.sql;hb=HEAD ------------------------------------------------------------------------ @@ -153,9 +153,9 @@ enclose small groups of queries in their own transaction. Use the following syntax: $dbw = wfGetDB( DB_MASTER ); -$dbw->begin(); +$dbw->begin( __METHOD__ ); /* Do queries */ -$dbw->commit(); +$dbw->commit( __METHOD__ ); Use of locking reads (e.g. the FOR UPDATE clause) is not advised. They are poorly implemented in InnoDB and will cause regular deadlock errors. diff --git a/docs/distributors.txt b/docs/distributors.txt index e9f151cf..4a654315 100644 --- a/docs/distributors.txt +++ b/docs/distributors.txt @@ -87,9 +87,9 @@ which the user can edit by hand thereafter. It's just a plain old PHP file, and can contain any PHP statements. It usually sets global variables that are used for configuration, and includes files used by any extensions. -Distributors cannot easily add extra statements to the autogenerated -LocalSettings.php at the present time -- although hacking mw-config/index.php -would work. It would be nice if this situation could be improved. +Distributors can easily add extra statements to the autogenerated +LocalSettings.php by changing mw-config/overrides.php (see that file for details +and examples). There's a new maintenance/install.php script which could be used for performing an install through the command line. @@ -106,6 +106,7 @@ intelligently: mail(). == Updates == + The correct way for updating a wiki is to update the files and then run from command line the maintenance/update.php script (with appropriate parameters if files were moved). It will perform all the needed steps to update the database diff --git a/docs/doxygen_first_page.php b/docs/doxygen_first_page.php index 11db1f58..9949d133 100644 --- a/docs/doxygen_first_page.php +++ b/docs/doxygen_first_page.php @@ -13,7 +13,7 @@ die("Not a valid entry point\n"); * Welcome on MediaWiki autogenerated documentation system. * * If you are looking to use, install or configure your wiki, you probably - * want to look at the main site: http://www.mediawiki.org/ + * want to look at the main site: https://www.mediawiki.org/ * * @note this page is generated from docs/doxygen_first_page.php */ diff --git a/docs/export-0.1.xsd b/docs/export-0.1.xsd index 0b3eb179..9ff48f03 100644 --- a/docs/export-0.1.xsd +++ b/docs/export-0.1.xsd @@ -2,57 +2,57 @@ <!-- This is an XML Schema description of the format output by MediaWiki's Special:Export system. - + The canonical URL to the schema document is: http://www.mediawiki.org/xml/export-0.1.xsd - + Use the namespace: http://www.mediawiki.org/xml/export-0.1/ --> <schema xmlns="http://www.w3.org/2001/XMLSchema" - xmlns:mw="http://www.mediawiki.org/xml/export-0.1/" - targetNamespace="http://www.mediawiki.org/xml/export-0.1/" - elementFormDefault="qualified"> + xmlns:mw="http://www.mediawiki.org/xml/export-0.1/" + targetNamespace="http://www.mediawiki.org/xml/export-0.1/" + elementFormDefault="qualified"> <annotation> <documentation xml:lang="en"> MediaWiki's page export format </documentation> </annotation> - + <!-- Need this to reference xml:lang --> <import namespace="http://www.w3.org/XML/1998/namespace" - schemaLocation="http://www.w3.org/2001/xml.xsd"/> - + schemaLocation="http://www.w3.org/2001/xml.xsd"/> + <!-- Our root element --> <element name="mediawiki" type="mw:MediaWikiType"/> - + <complexType name="MediaWikiType"> <sequence> <element name="page" type="mw:PageType" - minOccurs="0" maxOccurs="unbounded"/> + minOccurs="0" maxOccurs="unbounded"/> </sequence> <attribute name="version" type="string" use="required"/> <attribute ref="xml:lang" use="required"/> </complexType> - + <complexType name="PageType"> <sequence> <!-- Title in text form. (Using spaces, not underscores; with namespace ) --> <element name="title" type="string"/> - + <!-- optional page ID number --> <element name="id" type="positiveInteger" minOccurs="0"/> - + <!-- comma-separated list of string tokens, if present --> <element name="restrictions" type="string" minOccurs="0"/> - + <!-- Zero or more sets of revision data --> <element name="revision" type="mw:RevisionType" - minOccurs="0" maxOccurs="unbounded"/> + minOccurs="0" maxOccurs="unbounded"/> </sequence> </complexType> - + <complexType name="RevisionType"> <sequence> <element name="id" type="positiveInteger" minOccurs="0"/> @@ -63,12 +63,12 @@ <element name="text" type="string"/> </sequence> </complexType> - + <complexType name="ContributorType"> <sequence> <element name="username" type="string" minOccurs="0"/> <element name="id" type="positiveInteger" minOccurs="0" /> - + <element name="ip" type="string" minOccurs="0"/> </sequence> </complexType> diff --git a/docs/export-0.2.xsd b/docs/export-0.2.xsd index 8acbf543..55b05f8d 100644 --- a/docs/export-0.2.xsd +++ b/docs/export-0.2.xsd @@ -2,54 +2,54 @@ <!-- This is an XML Schema description of the format output by MediaWiki's Special:Export system. - + Version 0.2 adds optional basic file upload info support, which is used by our OAI export/import submodule. - + The canonical URL to the schema document is: http://www.mediawiki.org/xml/export-0.2.xsd - + Use the namespace: http://www.mediawiki.org/xml/export-0.2/ --> <schema xmlns="http://www.w3.org/2001/XMLSchema" - xmlns:mw="http://www.mediawiki.org/xml/export-0.2/" - targetNamespace="http://www.mediawiki.org/xml/export-0.2/" - elementFormDefault="qualified"> + xmlns:mw="http://www.mediawiki.org/xml/export-0.2/" + targetNamespace="http://www.mediawiki.org/xml/export-0.2/" + elementFormDefault="qualified"> <annotation> <documentation xml:lang="en"> MediaWiki's page export format </documentation> </annotation> - + <!-- Need this to reference xml:lang --> <import namespace="http://www.w3.org/XML/1998/namespace" - schemaLocation="http://www.w3.org/2001/xml.xsd"/> - + schemaLocation="http://www.w3.org/2001/xml.xsd"/> + <!-- Our root element --> <element name="mediawiki" type="mw:MediaWikiType"/> - + <complexType name="MediaWikiType"> <sequence> <element name="page" type="mw:PageType" - minOccurs="0" maxOccurs="unbounded"/> + minOccurs="0" maxOccurs="unbounded"/> </sequence> <attribute name="version" type="string" use="required"/> <attribute ref="xml:lang" use="required"/> </complexType> - + <complexType name="PageType"> <sequence> <!-- Title in text form. (Using spaces, not underscores; with namespace ) --> <element name="title" type="string"/> - + <!-- optional page ID number --> <element name="id" type="positiveInteger" minOccurs="0"/> - + <!-- comma-separated list of string tokens, if present --> <element name="restrictions" type="string" minOccurs="0"/> - + <!-- Zero or more sets of revision or upload data --> <choice minOccurs="0" maxOccurs="unbounded"> <element name="revision" type="mw:RevisionType" /> @@ -57,7 +57,7 @@ </choice> </sequence> </complexType> - + <complexType name="RevisionType"> <sequence> <element name="id" type="positiveInteger" minOccurs="0"/> @@ -68,33 +68,33 @@ <element name="text" type="string"/> </sequence> </complexType> - + <complexType name="ContributorType"> <sequence> <element name="username" type="string" minOccurs="0"/> <element name="id" type="positiveInteger" minOccurs="0" /> - + <element name="ip" type="string" minOccurs="0"/> </sequence> </complexType> - + <complexType name="UploadType"> <sequence> <!-- Revision-style data... --> <element name="timestamp" type="dateTime"/> <element name="contributor" type="mw:ContributorType"/> <element name="comment" type="string" minOccurs="0"/> - + <!-- Filename. (Using underscores, not spaces. No 'Image:' namespace marker.) --> <element name="filename" type="string"/> - + <!-- URI at which this resource can be obtained --> <element name="src" type="anyURI"/> - + <element name="size" type="positiveInteger" /> - + <!-- TODO: add other metadata fields --> </sequence> </complexType> - + </schema> diff --git a/docs/export-0.3.xsd b/docs/export-0.3.xsd index 1e0b7c88..ea2b816e 100644 --- a/docs/export-0.3.xsd +++ b/docs/export-0.3.xsd @@ -2,48 +2,48 @@ <!-- This is an XML Schema description of the format output by MediaWiki's Special:Export system. - + Version 0.2 adds optional basic file upload info support, which is used by our OAI export/import submodule. - + Version 0.3 adds some site configuration information such as a list of defined namespaces. - + The canonical URL to the schema document is: http://www.mediawiki.org/xml/export-0.3.xsd - + Use the namespace: http://www.mediawiki.org/xml/export-0.3/ --> <schema xmlns="http://www.w3.org/2001/XMLSchema" - xmlns:mw="http://www.mediawiki.org/xml/export-0.3/" - targetNamespace="http://www.mediawiki.org/xml/export-0.3/" - elementFormDefault="qualified"> + xmlns:mw="http://www.mediawiki.org/xml/export-0.3/" + targetNamespace="http://www.mediawiki.org/xml/export-0.3/" + elementFormDefault="qualified"> <annotation> <documentation xml:lang="en"> MediaWiki's page export format </documentation> </annotation> - + <!-- Need this to reference xml:lang --> <import namespace="http://www.w3.org/XML/1998/namespace" - schemaLocation="http://www.w3.org/2001/xml.xsd"/> - + schemaLocation="http://www.w3.org/2001/xml.xsd"/> + <!-- Our root element --> <element name="mediawiki" type="mw:MediaWikiType"/> - + <complexType name="MediaWikiType"> <sequence> <element name="siteinfo" type="mw:SiteInfoType" - minOccurs="0" maxOccurs="1"/> + minOccurs="0" maxOccurs="1"/> <element name="page" type="mw:PageType" - minOccurs="0" maxOccurs="unbounded"/> + minOccurs="0" maxOccurs="unbounded"/> </sequence> <attribute name="version" type="string" use="required"/> <attribute ref="xml:lang" use="required"/> </complexType> - + <complexType name="SiteInfoType"> <sequence> <element name="sitename" type="string" minOccurs="0" /> @@ -53,30 +53,30 @@ <element name="namespaces" type="mw:NamespacesType" minOccurs="0" /> </sequence> </complexType> - + <simpleType name="CaseType"> <restriction base="NMTOKEN"> <!-- Cannot have two titles differing only by case of first letter. --> <!-- Default behavior through 1.5, $wgCapitalLinks = true --> <enumeration value="first-letter" /> - + <!-- Complete title is case-sensitive --> <!-- Behavior when $wgCapitalLinks = false --> <enumeration value="case-sensitive" /> - + <!-- Cannot have two titles differing only by case. --> <!-- Not yet implemented as of MediaWiki 1.5 --> <enumeration value="case-insensitive" /> </restriction> </simpleType> - + <complexType name="NamespacesType"> <sequence> <element name="namespace" type="mw:NamespaceType" - minOccurs="0" maxOccurs="unbounded" /> + minOccurs="0" maxOccurs="unbounded" /> </sequence> </complexType> - + <complexType name="NamespaceType"> <simpleContent> <extension base="string"> @@ -84,18 +84,18 @@ </extension> </simpleContent> </complexType> - + <complexType name="PageType"> <sequence> <!-- Title in text form. (Using spaces, not underscores; with namespace ) --> <element name="title" type="string"/> - + <!-- optional page ID number --> <element name="id" type="positiveInteger" minOccurs="0"/> - + <!-- comma-separated list of string tokens, if present --> <element name="restrictions" type="string" minOccurs="0"/> - + <!-- Zero or more sets of revision or upload data --> <choice minOccurs="0" maxOccurs="unbounded"> <element name="revision" type="mw:RevisionType" /> @@ -103,7 +103,7 @@ </choice> </sequence> </complexType> - + <complexType name="RevisionType"> <sequence> <element name="id" type="positiveInteger" minOccurs="0"/> @@ -114,7 +114,7 @@ <element name="text" type="mw:TextType" /> </sequence> </complexType> - + <complexType name="TextType"> <simpleContent> <extension base="string"> @@ -122,33 +122,33 @@ </extension> </simpleContent> </complexType> - + <complexType name="ContributorType"> <sequence> <element name="username" type="string" minOccurs="0"/> <element name="id" type="positiveInteger" minOccurs="0" /> - + <element name="ip" type="string" minOccurs="0"/> </sequence> </complexType> - + <complexType name="UploadType"> <sequence> <!-- Revision-style data... --> <element name="timestamp" type="dateTime"/> <element name="contributor" type="mw:ContributorType"/> <element name="comment" type="string" minOccurs="0"/> - + <!-- Filename. (Using underscores, not spaces. No 'Image:' namespace marker.) --> <element name="filename" type="string"/> - + <!-- URI at which this resource can be obtained --> <element name="src" type="anyURI"/> - + <element name="size" type="positiveInteger" /> - + <!-- TODO: add other metadata fields --> </sequence> </complexType> - + </schema> diff --git a/docs/export-0.4.xsd b/docs/export-0.4.xsd index 3e7f2eab..b3ea3bf8 100644 --- a/docs/export-0.4.xsd +++ b/docs/export-0.4.xsd @@ -2,52 +2,52 @@ <!-- This is an XML Schema description of the format output by MediaWiki's Special:Export system. - + Version 0.2 adds optional basic file upload info support, which is used by our OAI export/import submodule. - + Version 0.3 adds some site configuration information such as a list of defined namespaces. - + Version 0.4 adds per-revision delete flags, log exports, discussion threading data, a per-page redirect flag, and per-namespace capitalization. The canonical URL to the schema document is: http://www.mediawiki.org/xml/export-0.4.xsd - + Use the namespace: http://www.mediawiki.org/xml/export-0.4/ --> <schema xmlns="http://www.w3.org/2001/XMLSchema" - xmlns:mw="http://www.mediawiki.org/xml/export-0.4/" - targetNamespace="http://www.mediawiki.org/xml/export-0.4/" - elementFormDefault="qualified"> + xmlns:mw="http://www.mediawiki.org/xml/export-0.4/" + targetNamespace="http://www.mediawiki.org/xml/export-0.4/" + elementFormDefault="qualified"> <annotation> <documentation xml:lang="en"> MediaWiki's page export format </documentation> </annotation> - + <!-- Need this to reference xml:lang --> <import namespace="http://www.w3.org/XML/1998/namespace" - schemaLocation="http://www.w3.org/2001/xml.xsd"/> - + schemaLocation="http://www.w3.org/2001/xml.xsd"/> + <!-- Our root element --> <element name="mediawiki" type="mw:MediaWikiType"/> - + <complexType name="MediaWikiType"> <sequence> <element name="siteinfo" type="mw:SiteInfoType" - minOccurs="0" maxOccurs="1"/> + minOccurs="0" maxOccurs="1"/> <element name="page" type="mw:PageType" - minOccurs="0" maxOccurs="unbounded"/> + minOccurs="0" maxOccurs="unbounded"/> </sequence> <attribute name="version" type="string" use="required"/> <attribute ref="xml:lang" use="required"/> </complexType> - + <complexType name="SiteInfoType"> <sequence> <element name="sitename" type="string" minOccurs="0" /> @@ -57,23 +57,23 @@ <element name="namespaces" type="mw:NamespacesType" minOccurs="0" /> </sequence> </complexType> - + <simpleType name="CaseType"> <restriction base="NMTOKEN"> <!-- Cannot have two titles differing only by case of first letter. --> <!-- Default behavior through 1.5, $wgCapitalLinks = true --> <enumeration value="first-letter" /> - + <!-- Complete title is case-sensitive --> <!-- Behavior when $wgCapitalLinks = false --> <enumeration value="case-sensitive" /> - + <!-- Cannot have non-case senstitive titles eg [[FOO]] == [[Foo]] --> <!-- Not yet implemented as of MediaWiki 1.18 --> <enumeration value="case-insensitive" /> </restriction> </simpleType> - + <simpleType name="DeletedFlagType"> <restriction base="NMTOKEN"> <enumeration value="deleted"/> @@ -83,10 +83,10 @@ <complexType name="NamespacesType"> <sequence> <element name="namespace" type="mw:NamespaceType" - minOccurs="0" maxOccurs="unbounded" /> + minOccurs="0" maxOccurs="unbounded" /> </sequence> </complexType> - + <complexType name="NamespaceType"> <simpleContent> <extension base="string"> @@ -95,33 +95,33 @@ </extension> </simpleContent> </complexType> - + <complexType name="PageType"> <sequence> <!-- Title in text form. (Using spaces, not underscores; with namespace ) --> <element name="title" type="string"/> - + <!-- optional page ID number --> <element name="id" type="positiveInteger" minOccurs="0"/> - + <!-- flag if the current revision is a redirect --> - <element name="redirect" minOccurs="0"/> + <element name="redirect" minOccurs="0"/> <!-- comma-separated list of string tokens, if present --> <element name="restrictions" type="string" minOccurs="0"/> - + <!-- Zero or more sets of revision or upload data --> <choice minOccurs="0" maxOccurs="unbounded"> <element name="revision" type="mw:RevisionType" /> <element name="upload" type="mw:UploadType" /> <element name="logitem" type="mw:LogItemType" /> </choice> - + <!-- Zero or One sets of discussion threading data --> <element name="discussionthreadinginfo" minOccurs="0" maxOccurs="1" type="mw:DiscussionThreadingInfo" /> </sequence> </complexType> - + <complexType name="RevisionType"> <sequence> <element name="id" type="positiveInteger" minOccurs="0"/> @@ -144,7 +144,7 @@ <element name="text" type="mw:TextType" /> </sequence> </complexType> - + <complexType name="CommentType"> <simpleContent> <extension base="string"> @@ -160,7 +160,7 @@ <extension base="string"> <attribute ref="xml:space" use="optional" default="preserve" /> <!-- This allows deleted=deleted on non-empty elements, but XSD is not omnipotent --> - <attribute name="deleted" use="optional" type="mw:DeletedFlagType"/> + <attribute name="deleted" use="optional" type="mw:DeletedFlagType"/> <!-- This isn't a good idea; we should be using "ID" instead of "NMTOKEN" --> <!-- However, "NMTOKEN" is strictest definition that is both compatible with existing --> <!-- usage ([0-9]+) and with the "ID" type. --> @@ -168,37 +168,37 @@ </extension> </simpleContent> </complexType> - + <complexType name="ContributorType"> <sequence> <element name="username" type="string" minOccurs="0"/> <element name="id" type="positiveInteger" minOccurs="0" /> - + <element name="ip" type="string" minOccurs="0"/> </sequence> <!-- This allows deleted=deleted on non-empty elements, but XSD is not omnipotent --> <attribute name="deleted" use="optional" type="mw:DeletedFlagType"/> </complexType> - + <complexType name="UploadType"> <sequence> <!-- Revision-style data... --> <element name="timestamp" type="dateTime"/> <element name="contributor" type="mw:ContributorType"/> <element name="comment" type="string" minOccurs="0"/> - + <!-- Filename. (Using underscores, not spaces. No 'Image:' namespace marker.) --> <element name="filename" type="string"/> - + <!-- URI at which this resource can be obtained --> <element name="src" type="anyURI"/> - + <element name="size" type="positiveInteger" /> - + <!-- TODO: add other metadata fields --> </sequence> </complexType> - + <!-- Discussion threading data for LiquidThreads --> <complexType name="DiscussionThreadingInfo"> <sequence> @@ -212,5 +212,5 @@ <element name="ThreadType" type="string" /> </sequence> </complexType> - + </schema> diff --git a/docs/export-0.5.xsd b/docs/export-0.5.xsd index 469446db..ed6c0029 100644 --- a/docs/export-0.5.xsd +++ b/docs/export-0.5.xsd @@ -2,54 +2,54 @@ <!-- This is an XML Schema description of the format output by MediaWiki's Special:Export system. - + Version 0.2 adds optional basic file upload info support, which is used by our OAI export/import submodule. - + Version 0.3 adds some site configuration information such as a list of defined namespaces. - + Version 0.4 adds per-revision delete flags, log exports, discussion threading data, a per-page redirect flag, and per-namespace capitalization. - + Version 0.5 adds byte count per revision. The canonical URL to the schema document is: http://www.mediawiki.org/xml/export-0.5.xsd - + Use the namespace: http://www.mediawiki.org/xml/export-0.5/ --> <schema xmlns="http://www.w3.org/2001/XMLSchema" - xmlns:mw="http://www.mediawiki.org/xml/export-0.5/" - targetNamespace="http://www.mediawiki.org/xml/export-0.5/" - elementFormDefault="qualified"> + xmlns:mw="http://www.mediawiki.org/xml/export-0.5/" + targetNamespace="http://www.mediawiki.org/xml/export-0.5/" + elementFormDefault="qualified"> <annotation> <documentation xml:lang="en"> MediaWiki's page export format </documentation> </annotation> - + <!-- Need this to reference xml:lang --> <import namespace="http://www.w3.org/XML/1998/namespace" - schemaLocation="http://www.w3.org/2001/xml.xsd"/> - + schemaLocation="http://www.w3.org/2001/xml.xsd"/> + <!-- Our root element --> <element name="mediawiki" type="mw:MediaWikiType"/> - + <complexType name="MediaWikiType"> <sequence> <element name="siteinfo" type="mw:SiteInfoType" - minOccurs="0" maxOccurs="1"/> + minOccurs="0" maxOccurs="1"/> <element name="page" type="mw:PageType" - minOccurs="0" maxOccurs="unbounded"/> + minOccurs="0" maxOccurs="unbounded"/> </sequence> <attribute name="version" type="string" use="required"/> <attribute ref="xml:lang" use="required"/> </complexType> - + <complexType name="SiteInfoType"> <sequence> <element name="sitename" type="string" minOccurs="0" /> @@ -59,23 +59,23 @@ <element name="namespaces" type="mw:NamespacesType" minOccurs="0" /> </sequence> </complexType> - + <simpleType name="CaseType"> <restriction base="NMTOKEN"> <!-- Cannot have two titles differing only by case of first letter. --> <!-- Default behavior through 1.5, $wgCapitalLinks = true --> <enumeration value="first-letter" /> - + <!-- Complete title is case-sensitive --> <!-- Behavior when $wgCapitalLinks = false --> <enumeration value="case-sensitive" /> - + <!-- Cannot have non-case senstitive titles eg [[FOO]] == [[Foo]] --> <!-- Not yet implemented as of MediaWiki 1.18 --> <enumeration value="case-insensitive" /> </restriction> </simpleType> - + <simpleType name="DeletedFlagType"> <restriction base="NMTOKEN"> <enumeration value="deleted"/> @@ -85,10 +85,10 @@ <complexType name="NamespacesType"> <sequence> <element name="namespace" type="mw:NamespaceType" - minOccurs="0" maxOccurs="unbounded" /> + minOccurs="0" maxOccurs="unbounded" /> </sequence> </complexType> - + <complexType name="NamespaceType"> <simpleContent> <extension base="string"> @@ -97,33 +97,33 @@ </extension> </simpleContent> </complexType> - + <complexType name="PageType"> <sequence> <!-- Title in text form. (Using spaces, not underscores; with namespace ) --> <element name="title" type="string"/> - + <!-- optional page ID number --> <element name="id" type="positiveInteger" minOccurs="0"/> - + <!-- flag if the current revision is a redirect --> - <element name="redirect" minOccurs="0"/> + <element name="redirect" minOccurs="0"/> <!-- comma-separated list of string tokens, if present --> <element name="restrictions" type="string" minOccurs="0"/> - + <!-- Zero or more sets of revision or upload data --> <choice minOccurs="0" maxOccurs="unbounded"> <element name="revision" type="mw:RevisionType" /> <element name="upload" type="mw:UploadType" /> <element name="logitem" type="mw:LogItemType" /> </choice> - + <!-- Zero or One sets of discussion threading data --> <element name="discussionthreadinginfo" minOccurs="0" maxOccurs="1" type="mw:DiscussionThreadingInfo" /> </sequence> </complexType> - + <complexType name="RevisionType"> <sequence> <element name="id" type="positiveInteger" minOccurs="0"/> @@ -146,7 +146,7 @@ <element name="text" type="mw:TextType" /> </sequence> </complexType> - + <complexType name="CommentType"> <simpleContent> <extension base="string"> @@ -162,7 +162,7 @@ <extension base="string"> <attribute ref="xml:space" use="optional" default="preserve" /> <!-- This allows deleted=deleted on non-empty elements, but XSD is not omnipotent --> - <attribute name="deleted" use="optional" type="mw:DeletedFlagType"/> + <attribute name="deleted" use="optional" type="mw:DeletedFlagType"/> <!-- This isn't a good idea; we should be using "ID" instead of "NMTOKEN" --> <!-- However, "NMTOKEN" is strictest definition that is both compatible with existing --> <!-- usage ([0-9]+) and with the "ID" type. --> @@ -171,37 +171,37 @@ </extension> </simpleContent> </complexType> - + <complexType name="ContributorType"> <sequence> <element name="username" type="string" minOccurs="0"/> <element name="id" type="positiveInteger" minOccurs="0" /> - + <element name="ip" type="string" minOccurs="0"/> </sequence> <!-- This allows deleted=deleted on non-empty elements, but XSD is not omnipotent --> <attribute name="deleted" use="optional" type="mw:DeletedFlagType"/> </complexType> - + <complexType name="UploadType"> <sequence> <!-- Revision-style data... --> <element name="timestamp" type="dateTime"/> <element name="contributor" type="mw:ContributorType"/> <element name="comment" type="string" minOccurs="0"/> - + <!-- Filename. (Using underscores, not spaces. No 'Image:' namespace marker.) --> <element name="filename" type="string"/> - + <!-- URI at which this resource can be obtained --> <element name="src" type="anyURI"/> - + <element name="size" type="positiveInteger" /> - + <!-- TODO: add other metadata fields --> </sequence> </complexType> - + <!-- Discussion threading data for LiquidThreads --> <complexType name="DiscussionThreadingInfo"> <sequence> @@ -215,5 +215,5 @@ <element name="ThreadType" type="string" /> </sequence> </complexType> - + </schema> diff --git a/docs/export-0.6.xsd b/docs/export-0.6.xsd index 55428b56..4668794e 100644 --- a/docs/export-0.6.xsd +++ b/docs/export-0.6.xsd @@ -2,57 +2,57 @@ <!-- This is an XML Schema description of the format output by MediaWiki's Special:Export system. - + Version 0.2 adds optional basic file upload info support, which is used by our OAI export/import submodule. - + Version 0.3 adds some site configuration information such as a list of defined namespaces. - + Version 0.4 adds per-revision delete flags, log exports, discussion threading data, a per-page redirect flag, and per-namespace capitalization. Version 0.5 adds byte count per revision. - + Version 0.6 adds a separate namespace tag, and resolves the - redirect target and adds a separate sha1 tag for each revision. - + redirect target and adds a separate sha1 tag for each revision. + The canonical URL to the schema document is: http://www.mediawiki.org/xml/export-0.6.xsd - + Use the namespace: http://www.mediawiki.org/xml/export-0.6/ --> <schema xmlns="http://www.w3.org/2001/XMLSchema" - xmlns:mw="http://www.mediawiki.org/xml/export-0.6/" - targetNamespace="http://www.mediawiki.org/xml/export-0.6/" - elementFormDefault="qualified"> + xmlns:mw="http://www.mediawiki.org/xml/export-0.6/" + targetNamespace="http://www.mediawiki.org/xml/export-0.6/" + elementFormDefault="qualified"> <annotation> <documentation xml:lang="en"> MediaWiki's page export format </documentation> </annotation> - + <!-- Need this to reference xml:lang --> <import namespace="http://www.w3.org/XML/1998/namespace" - schemaLocation="http://www.w3.org/2001/xml.xsd"/> - + schemaLocation="http://www.w3.org/2001/xml.xsd"/> + <!-- Our root element --> <element name="mediawiki" type="mw:MediaWikiType"/> - + <complexType name="MediaWikiType"> <sequence> <element name="siteinfo" type="mw:SiteInfoType" - minOccurs="0" maxOccurs="1"/> + minOccurs="0" maxOccurs="1"/> <element name="page" type="mw:PageType" - minOccurs="0" maxOccurs="unbounded"/> + minOccurs="0" maxOccurs="unbounded"/> </sequence> <attribute name="version" type="string" use="required"/> <attribute ref="xml:lang" use="required"/> </complexType> - + <complexType name="SiteInfoType"> <sequence> <element name="sitename" type="string" minOccurs="0" /> @@ -62,23 +62,23 @@ <element name="namespaces" type="mw:NamespacesType" minOccurs="0" /> </sequence> </complexType> - + <simpleType name="CaseType"> <restriction base="NMTOKEN"> <!-- Cannot have two titles differing only by case of first letter. --> <!-- Default behavior through 1.5, $wgCapitalLinks = true --> <enumeration value="first-letter" /> - + <!-- Complete title is case-sensitive --> <!-- Behavior when $wgCapitalLinks = false --> <enumeration value="case-sensitive" /> - + <!-- Cannot have non-case senstitive titles eg [[FOO]] == [[Foo]] --> <!-- Not yet implemented as of MediaWiki 1.18 --> <enumeration value="case-insensitive" /> </restriction> </simpleType> - + <simpleType name="DeletedFlagType"> <restriction base="NMTOKEN"> <enumeration value="deleted"/> @@ -88,10 +88,10 @@ <complexType name="NamespacesType"> <sequence> <element name="namespace" type="mw:NamespaceType" - minOccurs="0" maxOccurs="unbounded" /> + minOccurs="0" maxOccurs="unbounded" /> </sequence> </complexType> - + <complexType name="NamespaceType"> <simpleContent> <extension base="string"> @@ -100,36 +100,36 @@ </extension> </simpleContent> </complexType> - + <complexType name="PageType"> <sequence> <!-- Title in text form. (Using spaces, not underscores; with namespace ) --> <element name="title" type="string"/> - + <!-- Namespace in canonical form --> <element name="ns" type="positiveInteger"/> - + <!-- optional page ID number --> <element name="id" type="positiveInteger" minOccurs="0"/> - + <!-- flag if the current revision is a redirect --> - <element name="redirect" type="string" minOccurs="0"/> + <element name="redirect" type="string" minOccurs="0"/> <!-- comma-separated list of string tokens, if present --> <element name="restrictions" type="string" minOccurs="0"/> - + <!-- Zero or more sets of revision or upload data --> <choice minOccurs="0" maxOccurs="unbounded"> <element name="revision" type="mw:RevisionType" /> <element name="upload" type="mw:UploadType" /> <element name="logitem" type="mw:LogItemType" /> </choice> - + <!-- Zero or One sets of discussion threading data --> <element name="discussionthreadinginfo" minOccurs="0" maxOccurs="1" type="mw:DiscussionThreadingInfo" /> </sequence> </complexType> - + <complexType name="RevisionType"> <sequence> <element name="id" type="positiveInteger" minOccurs="0"/> @@ -153,7 +153,7 @@ <element name="text" type="mw:TextType" /> </sequence> </complexType> - + <complexType name="CommentType"> <simpleContent> <extension base="string"> @@ -169,7 +169,7 @@ <extension base="string"> <attribute ref="xml:space" use="optional" default="preserve" /> <!-- This allows deleted=deleted on non-empty elements, but XSD is not omnipotent --> - <attribute name="deleted" use="optional" type="mw:DeletedFlagType"/> + <attribute name="deleted" use="optional" type="mw:DeletedFlagType"/> <!-- This isn't a good idea; we should be using "ID" instead of "NMTOKEN" --> <!-- However, "NMTOKEN" is strictest definition that is both compatible with existing --> <!-- usage ([0-9]+) and with the "ID" type. --> @@ -178,37 +178,37 @@ </extension> </simpleContent> </complexType> - + <complexType name="ContributorType"> <sequence> <element name="username" type="string" minOccurs="0"/> <element name="id" type="positiveInteger" minOccurs="0" /> - + <element name="ip" type="string" minOccurs="0"/> </sequence> <!-- This allows deleted=deleted on non-empty elements, but XSD is not omnipotent --> <attribute name="deleted" use="optional" type="mw:DeletedFlagType"/> </complexType> - + <complexType name="UploadType"> <sequence> <!-- Revision-style data... --> <element name="timestamp" type="dateTime"/> <element name="contributor" type="mw:ContributorType"/> <element name="comment" type="string" minOccurs="0"/> - + <!-- Filename. (Using underscores, not spaces. No 'Image:' namespace marker.) --> <element name="filename" type="string"/> - + <!-- URI at which this resource can be obtained --> <element name="src" type="anyURI"/> - + <element name="size" type="positiveInteger" /> - + <!-- TODO: add other metadata fields --> </sequence> </complexType> - + <!-- Discussion threading data for LiquidThreads --> <complexType name="DiscussionThreadingInfo"> <sequence> @@ -222,5 +222,5 @@ <element name="ThreadType" type="string" /> </sequence> </complexType> - + </schema> diff --git a/docs/export-0.7.xsd b/docs/export-0.7.xsd new file mode 100644 index 00000000..48037463 --- /dev/null +++ b/docs/export-0.7.xsd @@ -0,0 +1,272 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<!-- + This is an XML Schema description of the format + output by MediaWiki's Special:Export system. + + Version 0.2 adds optional basic file upload info support, + which is used by our OAI export/import submodule. + + Version 0.3 adds some site configuration information such + as a list of defined namespaces. + + Version 0.4 adds per-revision delete flags, log exports, + discussion threading data, a per-page redirect flag, and + per-namespace capitalization. + + Version 0.5 adds byte count per revision. + + Version 0.6 adds a separate namespace tag, and resolves the + redirect target and adds a separate sha1 tag for each revision. + + Version 0.7 adds a unique identity constraint for both page and + revision identifiers. See also bug 4220. + Fix type for <ns> from "positiveInteger" to "nonNegativeInteger" to allow 0 + Moves <logitem> to its right location. + Add parentid to revision. + Fix type for <id> within <contributor> to "nonNegativeInteger" + + The canonical URL to the schema document is: + http://www.mediawiki.org/xml/export-0.7.xsd + + Use the namespace: + http://www.mediawiki.org/xml/export-0.7/ +--> +<schema xmlns="http://www.w3.org/2001/XMLSchema" + xmlns:mw="http://www.mediawiki.org/xml/export-0.7/" + targetNamespace="http://www.mediawiki.org/xml/export-0.7/" + elementFormDefault="qualified"> + + <annotation> + <documentation xml:lang="en"> + MediaWiki's page export format + </documentation> + </annotation> + + <!-- Need this to reference xml:lang --> + <import namespace="http://www.w3.org/XML/1998/namespace" + schemaLocation="http://www.w3.org/2001/xml.xsd" /> + + <!-- Our root element --> + <element name="mediawiki" type="mw:MediaWikiType"> + <!-- Page ID contraint, see bug 4220 --> + <unique name="PageIDConstraint"> + <selector xpath="mw:page" /> + <field xpath="mw:id" /> + </unique> + <!-- Revision ID contraint, see bug 4220 --> + <unique name="RevIDConstraint"> + <selector xpath="mw:page/mw:revision" /> + <field xpath="mw:id" /> + </unique> + </element> + + <complexType name="MediaWikiType"> + <sequence> + <element name="siteinfo" type="mw:SiteInfoType" + minOccurs="0" maxOccurs="1" /> + <element name="page" type="mw:PageType" + minOccurs="0" maxOccurs="unbounded" /> + <element name="logitem" type="mw:LogItemType" + minOccurs="0" maxOccurs="unbounded" /> + </sequence> + <attribute name="version" type="string" use="required" /> + <attribute ref="xml:lang" use="required" /> + </complexType> + + <complexType name="SiteInfoType"> + <sequence> + <element name="sitename" type="string" minOccurs="0" /> + <element name="base" type="anyURI" minOccurs="0" /> + <element name="generator" type="string" minOccurs="0" /> + <element name="case" type="mw:CaseType" minOccurs="0" /> + <element name="namespaces" type="mw:NamespacesType" minOccurs="0" /> + </sequence> + </complexType> + + <simpleType name="CaseType"> + <restriction base="NMTOKEN"> + <!-- Cannot have two titles differing only by case of first letter. --> + <!-- Default behavior through 1.5, $wgCapitalLinks = true --> + <enumeration value="first-letter" /> + + <!-- Complete title is case-sensitive --> + <!-- Behavior when $wgCapitalLinks = false --> + <enumeration value="case-sensitive" /> + + <!-- Cannot have non-case senstitive titles eg [[FOO]] == [[Foo]] --> + <!-- Not yet implemented as of MediaWiki 1.18 --> + <enumeration value="case-insensitive" /> + </restriction> + </simpleType> + + <simpleType name="DeletedFlagType"> + <restriction base="NMTOKEN"> + <enumeration value="deleted" /> + </restriction> + </simpleType> + + <complexType name="NamespacesType"> + <sequence> + <element name="namespace" type="mw:NamespaceType" + minOccurs="0" maxOccurs="unbounded" /> + </sequence> + </complexType> + + <complexType name="NamespaceType"> + <simpleContent> + <extension base="string"> + <attribute name="key" type="integer" /> + <attribute name="case" type="mw:CaseType" /> + </extension> + </simpleContent> + </complexType> + + <complexType name="RedirectType"> + <simpleContent> + <extension base="string"> + <attribute name="title" type="string" /> + </extension> + </simpleContent> + </complexType> + + <complexType name="PageType"> + <sequence> + <!-- Title in text form. (Using spaces, not underscores; with namespace ) --> + <element name="title" type="string" /> + + <!-- Namespace in canonical form --> + <element name="ns" type="nonNegativeInteger" /> + + <!-- optional page ID number --> + <element name="id" type="positiveInteger" /> + + <!-- flag if the current revision is a redirect --> + <element name="redirect" type="mw:RedirectType" minOccurs="0" maxOccurs="1" /> + + <!-- comma-separated list of string tokens, if present --> + <element name="restrictions" type="string" minOccurs="0" /> + + <!-- Zero or more sets of revision or upload data --> + <choice minOccurs="0" maxOccurs="unbounded"> + <element name="revision" type="mw:RevisionType" /> + <element name="upload" type="mw:UploadType" /> + </choice> + + <!-- Zero or One sets of discussion threading data --> + <element name="discussionthreadinginfo" minOccurs="0" maxOccurs="1" type="mw:DiscussionThreadingInfo" /> + </sequence> + </complexType> + + <complexType name="RevisionType"> + <sequence> + <element name="id" type="positiveInteger" /> + <element name="parentid" type="positiveInteger" minOccurs="0" /> + <element name="timestamp" type="dateTime" /> + <element name="contributor" type="mw:ContributorType" /> + <element name="minor" minOccurs="0" maxOccurs="1" /> + <element name="comment" type="mw:CommentType" minOccurs="0" maxOccurs="1" /> + <element name="sha1" type="string" /> + <element name="text" type="mw:TextType" /> + </sequence> + </complexType> + + <complexType name="LogItemType"> + <sequence> + <element name="id" type="positiveInteger" /> + <element name="timestamp" type="dateTime" /> + <element name="contributor" type="mw:ContributorType" /> + <element name="comment" type="mw:CommentType" minOccurs="0" /> + <element name="type" type="string" /> + <element name="action" type="string" /> + <element name="text" type="mw:LogTextType" minOccurs="0" maxOccurs="1" /> + <element name="logtitle" type="string" minOccurs="0" maxOccurs="1" /> + <element name="params" type="mw:LogParamsType" minOccurs="0" maxOccurs="1" /> + </sequence> + </complexType> + + <complexType name="CommentType"> + <simpleContent> + <extension base="string"> + <!-- This allows deleted=deleted on non-empty elements, but XSD is not omnipotent --> + <attribute name="deleted" use="optional" type="mw:DeletedFlagType" /> + </extension> + </simpleContent> + </complexType> + + <complexType name="TextType"> + <simpleContent> + <extension base="string"> + <attribute ref="xml:space" use="optional" default="preserve" /> + <!-- This allows deleted=deleted on non-empty elements, but XSD is not omnipotent --> + <attribute name="deleted" use="optional" type="mw:DeletedFlagType" /> + <!-- This isn't a good idea; we should be using "ID" instead of "NMTOKEN" --> + <!-- However, "NMTOKEN" is strictest definition that is both compatible with existing --> + <!-- usage ([0-9]+) and with the "ID" type. --> + <attribute name="id" type="NMTOKEN" /> + <attribute name="bytes" use="optional" type="nonNegativeInteger" /> + </extension> + </simpleContent> + </complexType> + + <complexType name="LogTextType"> + <simpleContent> + <extension base="string"> + <!-- This allows deleted=deleted on non-empty elements, but XSD is not omnipotent --> + <attribute name="deleted" use="optional" type="mw:DeletedFlagType" /> + </extension> + </simpleContent> + </complexType> + + <complexType name="LogParamsType"> + <simpleContent> + <extension base="string"> + <attribute ref="xml:space" use="optional" default="preserve" /> + </extension> + </simpleContent> + </complexType> + + <complexType name="ContributorType"> + <sequence> + <element name="username" type="string" minOccurs="0" /> + <element name="id" type="nonNegativeInteger" minOccurs="0" /> + + <element name="ip" type="string" minOccurs="0" /> + </sequence> + <!-- This allows deleted=deleted on non-empty elements, but XSD is not omnipotent --> + <attribute name="deleted" use="optional" type="mw:DeletedFlagType" /> + </complexType> + + <complexType name="UploadType"> + <sequence> + <!-- Revision-style data... --> + <element name="timestamp" type="dateTime" /> + <element name="contributor" type="mw:ContributorType" /> + <element name="comment" type="string" minOccurs="0" /> + + <!-- Filename. (Using underscores, not spaces. No 'File:' namespace marker.) --> + <element name="filename" type="string" /> + + <!-- URI at which this resource can be obtained --> + <element name="src" type="anyURI" /> + + <element name="size" type="positiveInteger" /> + + <!-- TODO: add other metadata fields --> + </sequence> + </complexType> + + <!-- Discussion threading data for LiquidThreads --> + <complexType name="DiscussionThreadingInfo"> + <sequence> + <element name="ThreadSubject" type="string" /> + <element name="ThreadParent" type="positiveInteger" /> + <element name="ThreadAncestor" type="positiveInteger" /> + <element name="ThreadPage" type="string" /> + <element name="ThreadID" type="positiveInteger" /> + <element name="ThreadAuthor" type="string" /> + <element name="ThreadEditStatus" type="string" /> + <element name="ThreadType" type="string" /> + </sequence> + </complexType> + +</schema> diff --git a/docs/export-demo.xml b/docs/export-demo.xml index 77b26a41..d198b93c 100644 --- a/docs/export-demo.xml +++ b/docs/export-demo.xml @@ -1,134 +1,149 @@ -<mediawiki xmlns="http://www.mediawiki.org/xml/export-0.4/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.mediawiki.org/xml/export-0.4/ http://www.mediawiki.org/xml/export-0.4.xsd" version="0.4" xml:lang="en"> - -<!-- Optional global configuration info --> -<siteinfo> - <!-- Site name, as set in $wgSitename --> - <sitename>DemoWiki</sitename> +<mediawiki xmlns="http://www.mediawiki.org/xml/export-0.7/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.mediawiki.org/xml/export-0.7/ http://www.mediawiki.org/xml/export-0.7.xsd" version="0.7" xml:lang="en"> - <!-- Forgot where you got this set? --> - <base>http://example.com/wiki/Main_Page</base> - - <!-- Source software version --> - <generator>MediaWiki 1.5.0</generator> - - <!-- Title case sensitivity options of the wiki this data came from --> - <!-- May be 'first-letter', 'case-sensitive', or 'case-insensitive' --> - <case>first-letter</case> - - <!-- Defined namespace keys on the source wiki. --> - <!-- Titles can be substring-split to obtain the symbolic numeric key --> - <namespaces> - <namespace key="-2">Media</namespace> - <namespace key="-1">Special</namespace> - <namespace key="0"></namespace> - <namespace key="1">Talk</namespace> - <namespace key="2">User</namespace> - <namespace key="3">User talk</namespace> - <namespace key="4">DemoWiki</namespace> - <namespace key="5">DemoWIki talk</namespace> - <namespace key="6">Image</namespace> - <namespace key="7">Image talk</namespace> - <namespace key="8">MediaWiki</namespace> - <namespace key="9">MediaWiki talk</namespace> - <namespace key="10">Template</namespace> - <namespace key="11">Template talk</namespace> - <namespace key="12">Help</namespace> - <namespace key="13">Help talk</namespace> - <namespace key="14">Category</namespace> - <namespace key="15">Category talk</namespace> - </namespaces> -</siteinfo> - -<!-- The rest of the data will be a series of page records --> -<page> - <!-- Titles are listed here in text form, with namespace prefix --> - <!-- if any, and spaces rather than the underscores used in URLs. --> - <title>Page title</title> + <!-- Optional global configuration info --> + <siteinfo> + <!-- Site name, as set in $wgSitename --> + <sitename>DemoWiki</sitename> + + <!-- Forgot where you got this set? --> + <base>http://example.com/wiki/Main_Page</base> + + <!-- Source software version --> + <generator>MediaWiki 1.20</generator> + + <!-- Title case sensitivity options of the wiki this data came from --> + <!-- May be 'first-letter', 'case-sensitive', or 'case-insensitive' --> + <case>first-letter</case> + + <!-- Defined namespace keys on the source wiki. --> + <namespaces> + <namespace key="-2" case="first-letter">Media</namespace> + <namespace key="-1" case="first-letter">Special</namespace> + <namespace key="0" case="first-letter" /> + <namespace key="1" case="first-letter">Talk</namespace> + <namespace key="2" case="first-letter">User</namespace> + <namespace key="3" case="first-letter">User talk</namespace> + <namespace key="4" case="first-letter">DemoWiki</namespace> + <namespace key="5" case="first-letter">DemoWIki talk</namespace> + <namespace key="6" case="first-letter">File</namespace> + <namespace key="7" case="first-letter">File talk</namespace> + <namespace key="8" case="first-letter">MediaWiki</namespace> + <namespace key="9" case="first-letter">MediaWiki talk</namespace> + <namespace key="10" case="first-letter">Template</namespace> + <namespace key="11" case="first-letter">Template talk</namespace> + <namespace key="12" case="first-letter">Help</namespace> + <namespace key="13" case="first-letter">Help talk</namespace> + <namespace key="14" case="first-letter">Category</namespace> + <namespace key="15" case="first-letter">Category talk</namespace> + </namespaces> + </siteinfo> - <!-- The page's immutable page_id number in the source database. --> - <!-- Page ID numbers are kept across page moves, but may change --> - <!-- if a page is deleted and recreated. --> - <id>1</id> - - <!-- Tag wether this article is a redirect --> - <!-- This corresponds to the page_is_redirect in the page table --> - <redirect /> + <!-- The rest of the data will be a series of page records --> + <page> + <!-- Titles are listed here in text form, with namespace prefix --> + <!-- if any, and spaces rather than the underscores used in URLs. --> + <title>Page title</title> + + <!-- Namespace in canonical form --> + <ns>0</ns> + + <!-- The page's immutable page_id number in the source database. --> + <!-- Page ID numbers are kept across page moves, but may change --> + <!-- if a page is deleted and recreated. --> + <id>1</id> + + <!-- Tag wether this article is a redirect and its target --> + <!-- This corresponds to the page_is_redirect in the page table --> + <redirect title="Target" /> + + <!-- If restricted, the ACL is listed here raw. --> + <restrictions>edit=sysop:move=sysop</restrictions> + + <!-- With a series of revision records... --> + + <!-- Remember this is XML; if you must use a regex-based extractor --> + <!-- in place of a standard XML parser, be very careful. --> + <!-- * Don't forget to decode character entities! --> + <!-- * If using a 'loose' XML parser, ensure that whitespace is --> + <!-- preserved in the <text> elements. --> + <revision> + <!-- Unique revision ID number (rev_id) in the source database. --> + <!-- This number uniquely identifies the revision on that wiki. --> + <id>100</id> + <!-- revision id of the parent revision --> + <parentid>99</parentid> + <timestamp>2001-01-15T13:15:00Z</timestamp> + <contributor> + <username>Foobar</username> + <id>42</id> + </contributor> + <minor /> + <comment>I have just one thing to say!</comment> + <sha1>5x0ux8iwjrbmfzgv6pkketxgkcnpr7h</sha1> + <text xml:space="preserve" bytes="25">A bunch of [[text]] here.</text> + </revision> + + <revision> + <id>99</id> + <timestamp>2001-01-15T13:10:27Z</timestamp> + <contributor> + <ip>10.0.0.2</ip> + </contributor> + <comment>new!</comment> + <sha1>etaxt3shcge6igz1biwy3d4um2pnle4</sha1> + <text xml:space="preserve" bytes="24">An earlier [[revision]].</text> + </revision> + </page> - <!-- If restricted, the ACL is listed here raw. --> - <restrictions>edit=sysop:move=sysop</restrictions> + <page> + <title>Talk:Page title</title> + <ns>1</ns> + <id>2</id> + <revision> + <id>101</id> + <timestamp>2001-01-15T14:03:00Z</timestamp> + <contributor><ip>10.0.0.2</ip></contributor> + <comment>hey</comment> + <sha1>ml80vmyjlixdstnywwihx003exfzq9j</sha1> + <text xml:space="preserve" bytes="47">WHYD YOU LOCK PAGE??!!! i was editing that jerk</text> + </revision> + </page> - <!-- With a series of revision records... --> + <page> + <title>File:Some image.jpg</title> + <ns>6</ns> + <id>3</id> + <revision> + <id>102</id> + <timestamp>2001-01-15T20:34:12Z</timestamp> + <contributor><username>Foobar</username><id>42</id></contributor> + <comment>My awesomeest image!</comment> + <sha1>mehom37npwkpzhaiwu3wyr0egalumki</sha1> + <text xml:space="preserve" bytes="52">This is an awesome little imgae. I lurves it. {{PD}}</text> + </revision> + <upload> + <timestamp>2001-01-15T20:34:12Z</timestamp> + <contributor><username>Foobar</username><id>42</id></contributor> + <comment>My awesomeest image!</comment> + <filename>Some_image.jpg</filename> + <src>http://upload.wikimedia.org/commons/2/22/Some_image.jpg</src> + <size>12345</size> + </upload> + </page> - <!-- Remember this is XML; if you must use a regex-based extractor --> - <!-- in place of a standard XML parser, be very careful. --> - <!-- * Don't forget to decode character entities! --> - <!-- * If using a 'loose' XML parser, ensure that whitespace is --> - <!-- preserved in the <text> elements. --> - <revision> - <!-- Unique revision ID number (rev_id) in the source database. --> - <!-- This number uniquely identifies the revision on that wiki. --> - <id>100</id> - - <timestamp>2001-01-15T13:15:00Z</timestamp> - <contributor><username>Foobar</username><id>42</id></contributor> - <minor /> - <comment>I have just one thing to say!</comment> - <text xml:space="preserve">A bunch of [[text]] here.</text> - </revision> + <!-- or a series of logitem records, but normaly page and logitem never exist both in one file --> + <logitem> + <id>15</id> + <timestamp>2008-10-23T03:20:32Z</timestamp> + <contributor> + <username>Wikimedian</username> + <id>12345</id> + </contributor> + <comment>content was: 'I think this was a silly edit'</comment> + <type>delete</type> + <action>delete</action> + <logtitle>Silly page name</logtitle> + <params xml:space="preserve" /> + </logitem> - <revision> - <timestamp>2001-01-15T13:10:27Z</timestamp> - <contributor><ip>10.0.0.2</ip></contributor> - <comment>new!</comment> - <text xml:space="preserve">An earlier [[revision]].</text> - </revision> -</page> - -<page> - <title>Talk:Page title</title> - <id>2</id> - <revision> - <id>101</id> - <timestamp>2001-01-15T14:03:00Z</timestamp> - <contributor><ip>10.0.0.2</ip></contributor> - <comment>hey</comment> - <text xml:space="preserve">WHYD YOU LOCK PAGE??!!! i was editing that jerk</text> - </revision> -</page> - -<page> - <title>Image:Some image.jpg</title> - <id>3</id> - <revision> - <id>102</id> - <timestamp>2001-01-15T20:34:12Z</timestamp> - <contributor><username>Foobar</username><id>42</id></contributor> - <comment>My awesomeest image!</comment> - <text xml:space="preserve">This is an awesome little imgae. I lurves it. {{PD}}</text> - </revision> - <upload> - <timestamp>2001-01-15T20:34:12Z</timestamp> - <contributor><username>Foobar</username><id>42</id></contributor> - <comment>My awesomeest image!</comment> - <filename>Some_image.jpg</filename> - <src>http://upload.wikimedia.org/commons/2/22/Some_image.jpg</src> - <size>12345</size> - </upload> -</page> - -<logitem> - <id>15</id> - <timestamp>2008-10-23T03:20:32Z</timestamp> - <contributor> - <username>Wikimedian</username> - <id>12345</id> - </contributor> - <comment>content was: 'I think this was a silly edit'</comment> - <type>delete</type> - <action>delete</action> - <logtitle>Silly page name</logtitle> - <params xml:space="preserve" /> -</logitem> - - </mediawiki> diff --git a/docs/hooks.txt b/docs/hooks.txt index a6f53c1a..ca64545f 100644 --- a/docs/hooks.txt +++ b/docs/hooks.txt @@ -245,6 +245,10 @@ $block: The block from which the autoblock is coming. 'AbortDiffCache': Can be used to cancel the caching of a diff &$diffEngine: DifferenceEngine object +'AbortEmailNotification': Can be used to cancel email notifications for an edit. +$editor: The User who made the change. +$title: The Title of the page that was edited. + 'AbortLogin': Return false to cancel account login. $user: the User object being authenticated against $password: the password being submitted, not yet checked for validity @@ -262,7 +266,7 @@ $reason: the reason for the move (added in 1.13) 'AbortNewAccount': Return false to cancel explicit account creation. $user: the User object about to be created (read-only, incomplete) -&$msg: out parameter: name of error message to display on abort +&$msg: out parameter: HTML to display on abort 'ActionBeforeFormDisplay': before executing the HTMLForm object $name: name of the action @@ -286,11 +290,17 @@ $revCount: Number of revisions in the XML file $sRevCount: Number of sucessfully imported revisions $pageInfo: associative array of page information +'AfterFinalPageOutput': Nearly at the end of OutputPage::output() but +before OutputPage::sendCacheControl() and final ob_end_flush() which +will send the buffered output to the client. This allows for last-minute +modification of the output within the buffer by using ob_get_clean(). +$output: The OutputPage object where output() was called + 'AjaxAddScript': Called in output page just before the initialisation of the javascript ajax engine. The hook is only called when ajax is enabled ( $wgUseAjax = true; ). -'AlternateEdit': before checking if an user can edit a page and +'AlternateEdit': before checking if a user can edit a page and before showing the edit form ( EditPage::edit() ). This is triggered on &action=edit. $EditPage: the EditPage object @@ -310,6 +320,14 @@ $body: Body of the message Use this to extend core API modules. &$module: Module object +'ApiCheckCanExecute': Called during ApiMain::checkCanExecute. Use to +further authenticate and authorize API clients before executing the +module. Return false and set a message to cancel the request. +$module: Module object +$user: Current user +&$message: API usage message to die with, as a message key or array +as accepted by ApiBase::dieUsageMsg. + 'APIEditBeforeSave': before saving a page with api.php?action=edit, after processing request parameters. Return false to let the request fail, returning an error message or an <edit result="Failure"> tag @@ -331,6 +349,11 @@ descriptions. &$module: ApiBase Module object &$desc: Array of parameter descriptions +'APIGetResultProperties': use this hook to mofify the properties +in a module's result. +&$module: ApiBase Module object +&$properties: Array of properties + 'APIQueryAfterExecute': after calling the execute() method of an action=query submodule. Use this to extend core API modules. &$module: Module object @@ -388,6 +411,11 @@ is the User object. In the hook, just add your callback to the $tokenFunctions array and return true (returning false makes no sense) $tokenFunctions: array(action => callback) +'ApiMain::onException': Called by ApiMain::executeActionWithErrorHandling() +when an exception is thrown during API action execution. +$apiMain: Calling ApiMain instance. +$e: Exception object. + 'ApiRsdServiceApis': Add or remove APIs from the RSD services list. Each service should have its own entry in the $apis array and have a unique name, passed as key for the array that represents the service data. @@ -395,6 +423,11 @@ In this data array, the key-value-pair identified by the apiLink key is required. &$apis: array of services +'ApiTokensGetTokenTypes': use this hook to extend action=tokens with new +token types. +&$tokenTypes: supported token types in format 'type' => callback function +used to retrieve this type of tokens. + 'ArticleAfterFetchContent': after fetching content of an article from the database $article: the article (object) being loaded from the database @@ -417,6 +450,8 @@ $user: the user (object) deleting the article $reason: the reason (string) the article is being deleted $error: if the deletion was prohibited, the (raw HTML) error message to display (added in 1.13) +$status: Status object, modify this to throw an error. Overridden by $error + (added in 1.20) 'ArticleDeleteComplete': after an article is deleted $article: the WikiPage that was deleted @@ -667,6 +702,10 @@ $output: OutputPage object in use 'CategoryPageView': before viewing a categorypage in CategoryPage::view $catpage: CategoryPage instance +'ChangePasswordForm': For extensions that need to add a field to the ChangePassword form +via the Preferences form +&$extraFields: An array of arrays that hold fields like would be passed to the pretty function. + 'ChangesListInsertArticleLink': Override or augment link to article in RC list. &$changesList: ChangesList instance. &$articlelink: HTML of link to article (already filled-in). @@ -687,10 +726,18 @@ $user: user (object) whose email is being confirmed &$pager: Pager object for contributions &$queryInfo: The query for the contribs Pager +'ContribsPager::reallyDoQuery': Called before really executing the query for My Contributions +&$data: an array of results of all contribs queries +$pager: The ContribsPager object hooked into +$offset: Index offset, inclusive +$limit: Exact query limit +$descending: Query direction, false for ascending, true for descending + 'ContributionsLineEnding': Called before a contributions HTML line is finished $page: SpecialPage object for contributions -$ret: the HTML line +&$ret: the HTML line $row: the DB row for this line +&$classes: the classes to add to the surrounding <li> 'ContributionsToolLinks': Change tool links above Special:Contributions $id: User identifier @@ -735,11 +782,11 @@ $title: Title object for the title being linked to (may not be the same as $wgTitle, if the section is included from a template) $section: The designation of the section being pointed to, to be included in the link, like "§ion=$section" -$tooltip: The default tooltip. Escape with htmlspecialchars() before using. +$tooltip: The default tooltip. Escape before using. By default, this is wrapped in the 'editsectionhint' message. &$result: The HTML to return, prefilled with the default plus whatever other changes earlier hooks have made -$lang: The language code to use for the link in the wfMsg* functions +$lang: The language code to use for the link in the wfMessage function 'EditFilter': Perform checks on an edit $editor: Edit form (see includes/EditPage.php) @@ -774,12 +821,13 @@ $request: Webrequest return value is ignored (should always return true) 'EditPage::showEditForm:fields': allows injection of form field into edit form -&$editor: the EditPage instance for reference -&$out: an OutputPage instance to write to +$editor: the EditPage instance for reference +$out: an OutputPage instance to write to return value is ignored (should always return true) 'EditPage::showEditForm:initial': before showing the edit form $editor: EditPage instance (object) +$out: an OutputPage instance to write to Return false to halt editing; you'll need to handle error messages, etc. yourself. Alternatively, modifying $error and returning true will cause the @@ -839,7 +887,7 @@ $title: Title being linked to $section: Section to link to $link: Default link &$result: Result (alter this to override the generated links) -$lang: The language code to use for the link in the wfMsg* functions +$lang: The language code to use for the link in the wfMessage function 'EmailConfirmed': When checking that the user's email address is "confirmed" $user: User being checked @@ -898,6 +946,12 @@ $article: in case all revisions of the file are deleted a reference to the $user: user who performed the deletion $reason: reason +'FileTransformed': When a file is transformed and moved into storage +$file: reference to the File object +$thumb: the MediaTransformOutput object +$tmpThumbPath: The temporary file system path of the transformed file +$thumbPath: The permanent storage path of the transformed file + 'FileUpload': When a file upload occurs $file : Image object representing the file that was uploaded $reupload : Boolean indicating if there was a previously another image there or not (since 1.17) @@ -909,6 +963,14 @@ $fileVersions: array of undeleted versions. Empty if all versions were restored $user: user who performed the undeletion $reason: reason +'FormatAutocomments': When an autocomment is formatted by the Linker + &$comment: Reference to the accumulated comment. Initially null, when set the default code will be skipped. + $pre: Initial part of the parsed comment before the call to the hook. + $auto: The extracted part of the parsed comment before the call to the hook. + $post: The final part of the parsed comment before the call to the hook. + $title: An optional title object used to links to sections. Can be null. + $local: Boolean indicating whether section links should refer to local page. + 'GetAutoPromoteGroups': When determining which autopromote groups a user is entitled to be in. &$user: user to promote. @@ -996,6 +1058,11 @@ $result: User permissions error to add. If none, return true. 'getUserPermissionsErrorsExpensive': Absolutely the same, but is called only if expensive checks are enabled. +'GitViewers': called when generating the list of git viewers for Special:Version, use + this to change the list. +&$extTypes: associative array of repo URLS to viewer URLs. + + 'ImageBeforeProduceHTML': Called before producing the HTML created by a wiki image insertion. You can skip the default logic entirely by returning false, or just modify a few things using call-by-reference. @@ -1003,9 +1070,9 @@ $result: User permissions error to add. If none, return true. &$title: Title object of the image &$file: File object, or false if it doesn't exist &$frameParams: Various parameters with special meanings; see documentation in - includes/Linker.php for Linker::makeImageLink2 + includes/Linker.php for Linker::makeImageLink &$handlerParams: Various parameters with special meanings; see documentation in - includes/Linker.php for Linker::makeImageLink2 + includes/Linker.php for Linker::makeImageLink &$time: Timestamp of file in 'YYYYMMDDHHIISS' string form, or false for current &$res: Final HTML output, used if you return false @@ -1072,6 +1139,10 @@ $reader: XMLReader object $revisionInfo: Array of information Return false to stop further processing of the tag +'InfoAction': When building information to display on the action=info page +$context: IContextSource object +&$pageInfo: Array of information + 'InitializeArticleMaybeRedirect': MediaWiki check to see if title is a redirect $title: Title object ($wgTitle) $request: WebRequest @@ -1085,8 +1156,16 @@ $prefix: interwiki prefix we are looking for. &$iwData: output array describing the interwiki with keys iw_url, iw_local, iw_trans and optionally iw_api and iw_wikiid. +'InternalParseBeforeSanitize': during Parser's internalParse method just before the +parser removes unwanted/dangerous HTML tags and after nowiki/noinclude/includeonly/ +onlyinclude and other processings. Ideal for syntax-extensions after template/parser +function execution which respect nowiki and HTML-comments. +&$parser: Parser object +&$text: string containing partially parsed text +&$stripState: Parser's internal StripState object + 'InternalParseBeforeLinks': during Parser's internalParse method before links -but after noinclude/includeonly/onlyinclude and other processing. +but after nowiki/noinclude/includeonly/onlyinclude and other processings. &$parser: Parser object &$text: string containing partially parsed text &$stripState: Parser's internal StripState object @@ -1227,7 +1306,7 @@ $param: Associative Array with the following additional options: - lim Integer Limit of items to show, default is 50 - conds Array Extra conditions for the query (e.g. "log_action != 'revision'") - showIfEmpty boolean Set to false if you don't want any output in case the loglist is empty if set to true (default), "No matching items in log" is displayed if loglist is empty - - msgKey Array If you want a nice box with a message, set this to the key of the message. First element is the message key, additional optional elements are parameters for the key that are processed with wfMsgExt and option 'parse' + - msgKey Array If you want a nice box with a message, set this to the key of the message. First element is the message key, additional optional elements are parameters for the key that are processed with wfMessage()->params()->parseAsBlock() - offset Set to overwrite offset parameter in $wgRequest set to '' to unset offset - wrap String Wrap the message in html (usually something like "<div ...>$1</div>"). - flags Integer display flags (NO_ACTION_LINK,NO_EXTRA_USER_LINKS) @@ -1243,7 +1322,7 @@ $data: Associative array of data for handlers to record. It must include values - 'comment' Wikitext string in the same format as an edit summary - 'timestamp' Timestamp when the action occured -LoginAuthenticateAudit': a login attempt for a valid user account either +'LoginAuthenticateAudit': a login attempt for a valid user account either succeeded or failed. No return data is accepted; this hook is for auditing only. $user: the User object being authenticated against $password: the password being submitted and found wanting @@ -1334,6 +1413,11 @@ using this hook. BaseTemplate::makeListItem for details on the format of individual items inside of this array +'NamespaceIsMovable': Called when determining if it is possible to pages in a namespace. +$index: Integer; the index of the namespace being checked. +$result: Boolean; whether MediaWiki currently thinks that pages in this namespace are movable. +Hooks may change this value to override the return value of MWNamespace::isMovable() + 'NewRevisionFromEditComplete': called when a revision was inserted due to an edit $article: the WikiPage edited @@ -1421,6 +1505,12 @@ A parser extension which depends on user options should install this hook and append its values to the key. $hash: reference to a hash key string which can be modified +'ParserAfterParse': Called from Parser::parse() just after the call to +Parser::internalParse() returns +$parser: parser object +$text: text being parsed +$stripState: stripState used (object) + 'ParserAfterStrip': Same as ParserBeforeStrip 'ParserAfterTidy': Called after Parser::tidy() in Parser::parse() @@ -1477,6 +1567,7 @@ to modify the parameters of the image. $title: title object representing the file $file: file object that will be used to create the image &$params: 2-D array of parameters +$parser: Parser object that called the hook 'ParserSectionCreate': Called each time the parser creates a document section from wikitext. Use this to apply per-section modifications to HTML (like @@ -1493,6 +1584,10 @@ $showEditLinks: boolean describing whether this section has an edit link maintenance/parserTests.inc $parser: Parser object created +'ParserTestGlobals': Allows to define globals for parser tests. +&$globals: Array with all the globals which should be set for parser tests. + The arrays keys serve as the globals names, its values are the globals values. + 'ParserTestTables': alter the list of tables to duplicate when parser tests are run. Use when page save hooks require the presence of custom tables to ensure that tests continue to run properly. @@ -1520,7 +1615,7 @@ Return false and put the merged text into $text to override the default behavior 'PreferencesGetLegend': Override the text used for the <legend> of a preferences section $form: the PreferencesForm object. This is a ContextSource as well $key: the section name -&$legend: the legend text. Defaults to wfMsg( "prefs-$key" ) but may be overridden +&$legend: the legend text. Defaults to wfMessage( "prefs-$key" )->text() but may be overridden 'PrefixSearchBackend': Override the title prefix search used for OpenSearch and AJAX search suggestions. Put results into &$results outparam and return false. @@ -1558,6 +1653,11 @@ $out: OutputPage object 'RecentChange_save': called at the end of RecentChange::save() $recentChange: RecentChange object +'RedirectSpecialArticleRedirectParams': lets you alter the set of +parameter names such as "oldid" that are preserved when using +redirecting special pages such as Special:MyPage and Special:MyTalk. +&$redirectParams: An array of parameters preserved by redirecting special pages. + 'RequestContextCreateSkin': Called when RequestContext::getSkin creates a skin instance. Can be used by an extension override what skin is used in certain contexts. IContextSource $context: The RequestContext the skin is being created for. @@ -1621,6 +1721,11 @@ in the $searchEngine->namespaces array. $query : Original query. &$parsed : Resultant query with the prefixes stripped. +'SearchResultInitFromTitle': Set the revision used when displaying a page in +search results. +$title : Current Title object being displayed in search results. +&$id: Revision ID (default is false, for latest) + 'SearchableNamespaces': An option to modify which namespaces are searchable. &$arr : Array of namespaces ($nsId => $name) which will be used. @@ -1788,6 +1893,14 @@ Each key maps to an associative array with a 'msg' (message key) and a 'default' hook to remove a core special page $list: list (array) of core special pages +'SpecialPageAfterExecute': called after SpecialPage::execute +$special: the SpecialPage object +$subPage: the subpage string or null if no subpage was specified + +'SpecialPageBeforeExecute': called before SpecialPage::execute +$special: the SpecialPage object +$subPage: the subpage string or null if no subpage was specified + 'SpecialPasswordResetOnSubmit': when executing a form submission on Special:PasswordReset $users: array of User objects $data: array of data submitted by the user @@ -1908,6 +2021,12 @@ $title: The title in question. $title: Title object that is being checked $result: Boolean; whether MediaWiki currently thinks this is a CSS/JS page. Hooks may change this value to override the return value of Title::isCssOrJsPage() +'TitleIsAlwaysKnown': Called when determining if a page exists. +Allows overriding default behaviour for determining if a page exists. +If $isKnown is kept as null, regular checks happen. If it's a boolean, this value is returned by the isKnown method. +$title: Title object that is being checked +$result: Boolean|null; whether MediaWiki currently thinks this page is known + 'TitleIsMovable': Called when determining if it is possible to move a page. Note that this hook is not called for interwiki pages or pages in immovable namespaces: for these, isMovable() always returns false. $title: Title object that is being checked @@ -2234,9 +2353,9 @@ One, and only one hook should set this, and return false. &$opts: Options to use for the query &$join: Join conditions -'wfShellMaintenanceCmd': Called when generating a shell-escaped command line - string to run a maintenance script. -&$script: MediaWiki maintenance script path +'wfShellWikiCmd': Called when generating a shell-escaped command line + string to run a MediaWiki cli script. +&$script: MediaWiki cli script path &$parameters: Array of arguments and options to the script &$options: Associative array of options, may contain the 'php' and 'wrapper' keys diff --git a/docs/language.txt b/docs/language.txt index 1df98810..42a60279 100644 --- a/docs/language.txt +++ b/docs/language.txt @@ -1,21 +1,5 @@ language.txt -The Language object handles all readable text produced by the software. The most -used function is getMessage(), usually called with the wrapper function wfMsg() -which calls that method on the global language object. It just returns a piece -of text given a text key. It is recommended that you use each key only -once--bits of text in different contexts that happen to be identical in English -may not be in other languages, so it's better to add new keys than to reuse them -a lot. Likewise, if there is text that gets combined with things like names and -titles, it is better to put markers like "$1" inside a piece of text and use -str_replace() than to compose such messages in code, because their order may -change in other languages too. +The Language object handles all readable text produced by the software. -While the system is running, there will be one global language object, which -will be a subtype of Language. The methods in these objects will return the -native text requested if available, otherwise they fall back to sending English -text (which is why the LanguageEn object has no code at all--it just inherits -the English defaults of the Language base class). - -The names of the namespaces are also contained in the language object, though -the numbers are fixed. +See http://www.mediawiki.org/wiki/Localisation#General_use_.28for_developers.29 diff --git a/docs/magicword.txt b/docs/magicword.txt index ceae0262..1d9bf7d4 100644 --- a/docs/magicword.txt +++ b/docs/magicword.txt @@ -40,7 +40,7 @@ $magicWords['es'] = array( ); ---- -$wgExtensionMessagesFiles['ExtensionNameMagic'] = dirname( __FILE__ ) . '/ExtensionName.i18n.magic.php'; +$wgExtensionMessagesFiles['ExtensionNameMagic'] = __DIR__ . '/ExtensionName.i18n.magic.php'; $wgHooks['MagicWordwgVariableIDs'][] = 'wfAddCustomMagicWordID'; $wgHooks['ParserGetVariableValueSwitch'][] = 'wfGetCustomMagicWordValue'; @@ -74,7 +74,7 @@ $magicWords['es'] = array( ); ---- -$wgExtensionMessagesFiles['ExtensionNameMagic'] = dirname( __FILE__ ) . '/ExtensionName.i18n.magic.php'; +$wgExtensionMessagesFiles['ExtensionNameMagic'] = __DIR__ . '/ExtensionName.i18n.magic.php'; $wgHooks['ParserFirstCallInit'][] = 'wfRegisterCustomMagicWord'; function wfRegisterCustomMagicWord( &$parser ){ diff --git a/docs/memcached.txt b/docs/memcached.txt index f5384f9d..3872edc8 100644 --- a/docs/memcached.txt +++ b/docs/memcached.txt @@ -138,7 +138,7 @@ Message Cache: key: $wgDBname:messages, $wgDBname:messages-hash, $wgDBname:messages-status ex: wikidb:messages, wikidb:messages-hash, wikidb:messages-status stores: an array where the keys are DB keys and the values are messages - set in: wfMsg(), Article::editUpdates() and Title::moveTo() + set in: wfMessage(), Article::editUpdates() and Title::moveTo() expriy: $wgMsgCacheExpiry cleared by: nothing diff --git a/docs/uidesign/mediawiki.action.history.diff.html b/docs/uidesign/mediawiki.action.history.diff.html index fdc54aa3..7b8eb2a0 100644 --- a/docs/uidesign/mediawiki.action.history.diff.html +++ b/docs/uidesign/mediawiki.action.history.diff.html @@ -5,9 +5,9 @@ </head> <body style="background-color: #C0C0C0;"> <p> -This show various styles for our diff action, the background being hardcoded to gray (<tt>#C0C0C0</tt>) The reference style sheet is:</p> +This show various styles for our diff action, the background being hardcoded to gray (<code>#C0C0C0</code>) The reference style sheet is:</p> <p> -<tt><a href="../../resources/mediawiki.action/mediawiki.action.history.diff.css">resources/mediawiki.action/mediawiki.action.history.diff.css</a></tt>. +<code><a href="../../resources/mediawiki.action/mediawiki.action.history.diff.css">resources/mediawiki.action/mediawiki.action.history.diff.css</a></code>. </p> <p> This file might help us fix our diff colors which have been a recurring issues among the community for a loooong time.</p> @@ -35,12 +35,12 @@ Below are some basic lines being applied one or two classes. Mainly for debuggin <tr><th>Diff</th></tr> - <tr><td class="diff-addedline"><tt>diff-addedline</tt>: added line</td></tr> - <tr><td class="diff-deletedline"><tt>diff-deletedline</tt>: deleted line</td></tr> - <tr><td class="diff-context"><tt>diff-context</tt>: context</td></tr> + <tr><td class="diff-addedline"><code>diff-addedline</code>: added line</td></tr> + <tr><td class="diff-deletedline"><code>diff-deletedline</code>: deleted line</td></tr> + <tr><td class="diff-context"><code>diff-context</code>: context</td></tr> - <tr><th>Same as above with a <tt><span></tt> child element having the <tt>diffchange</tt> class</th></tr> + <tr><th>Same as above with a <code><span></code> child element having the <code>diffchange</code> class</th></tr> <tr><td class="diffchange">Diffchange</td></tr> <tr><td class="diff-addedline"> |