Avoid exceptions by first checking language code validity
[lhc/web/wiklou.git] / RELEASE-NOTES-1.22
1 Security reminder: MediaWiki does not require PHP's register_globals. If you
2 have it on, turn it '''off''' if you can.
3
4 == MediaWiki 1.22 ==
5
6 THIS IS NOT A RELEASE YET
7
8 MediaWiki 1.22 is an alpha-quality branch and is not recommended for use in
9 production.
10
11 === Configuration changes in 1.22 ===
12 * $wgRedirectScript was removed. It was unused.
13 * Removed $wgLocalMessageCacheSerialized, it is now always true.
14 * When $wgUseVFormUserLogin is true, the redesign of Special:UserLogin is
15 activated; when $wgUseVFormCreateAccount is true, the redesign of
16 Special:UserLogin/signup is activated.
17 * $wgVectorUseIconWatch is now enabled by default.
18 * $wgCascadingRestrictionLevels was added.
19 * ftps, ssh, sftp, xmpp, sip, sips, tel, sms, bitcoin, magnet, urn, and geo
20 have been whitelisted inside of $wgUrlProtocols.
21 * $wgDocType and $wgDTD have been removed and are no longer used for the DOCTYPE.
22 * $wgHtml5 is no longer used by core. Setting it to false will no longer disable HTML5.
23 It is still set to true for extension compatibility but doing so in extensions is deprecated.
24 * $wgXhtmlDefaultNamespace is no longer used by core. Setting it will no longer change the
25 xmlns used by MediaWiki. Reliance on this variable by extensions is deprecated.
26 * $wgHandheldStyle was removed.
27 * $wgHandheldForIPhone was removed.
28 * $wgJsMimeType is no longer used by core. Most usage has been removed since
29 HTML output is now exclusively HTML5.
30 * $wgDBOracleDRCP added. True enables persistent connection with DRCP on Oracle.
31 * $wgLogAutopatrol added to allow disabling logging of autopatrol edits in the logging table.
32 default for $wgLogAutopatrol is true.
33 * The 'edit' right no longer allows for editing a user's own CSS and JS.
34 * New rights 'editmyusercss' and 'editmyuserjs' restrict actions that were
35 formerly allowed by default. They have been added to the default for
36 $wgGroupPermissions['*'].
37
38 === New features in 1.22 ===
39 * (bug 44525) mediawiki.jqueryMsg can now parse (whitelisted) HTML elements and attributes.
40 * (bug 33454) Language::sprintfDate now has a timezone parameter, and supports
41 the "eIOPTZ" formatting characters.
42 * EditWarning: A warning is shown when an editor leaves the edit form without
43 saving (enabled by default, users can opt-out via the 'useeditwarning'
44 preference). This feature was moved from the Vector extension, and is now part
45 of core for all skins. Take care when upgrading that you don't use an older
46 version of the Vector extension as this feature may conflict.
47 * New 'mediawiki.ui' CSS module providing mw-ui-* styles for buttons and a
48 compact vertical form layout.
49 * New versions of login (Special:UserLogin) and create account
50 (Special:UserLogin/signup) forms. They are opt-in for now, controlled by
51 the $wgUseVFormUserLogin and $wgUseVFormCreateAccount settings or a 'useNew'
52 URL parameter trigger.
53 * (bug 23343) Implemented ability to apply IP blocks to the contents of X-Forwarded-For headers
54 by adding a new configuration variable $wgApplyIpBlocksToXff (disabled by default).
55 * The new hook 'APIGetPossibleErrors' to modify the list of possible errors was
56 added.
57 * (bug 25592) LogEventsList::showLogExtract() will now ignore various
58 Pager-related WebRequest parameters by default, as this is overwhelmingly
59 likely to be what was intended by users of the method. If any caller wishes
60 to use these parameters, the new param 'useRequestParams' may be set to true.
61 * mw.util.addPortletLink: Tooltip is no longer required to be plain (without
62 an accesskey in it already). As such it now rountrips. Creating a link with a
63 message as tooltip, grabbing the title attribute and using it to create
64 another portlet will work as expected.
65 * (bug 6747) {{ROOTPAGENAME}} introduced, contains the name of the topmost
66 page without namespace.
67 * BREAKING CHANGE: (bug 41729) Display editsection links next to headings. Also
68 change their class name from .editsection to .mw-editsection and place them at
69 the end of the heading element instead of the beginning. Client-side code and
70 screen-scrapers will have to be adjusted to handle both cases (old HTML will
71 still be visible on cached page renders until they are purged); extensions
72 using the DoEditSectionLink or EditSectionLink hooks might need adjustments as
73 well.
74 * (bug 45535) introduced the new 'LanguageLinks' hook for manipulating the
75 language links associated with a page before display.
76 * Chosen (http://harvesthq.github.io/chosen/) was added as module 'jquery.chosen'
77 * HTMLForm will turn multiselect checkboxes into a Chosen interface when setting cssclass 'mw-chosen'
78 * rebuildLocalisationCache learned --lang option. Let you rebuild l10n caches
79 of the specified languages instead of all of them.
80 * New GetNewMessagesAlert hook allowing extensions to disable or modify the new
81 messages alert
82 * New wgUserNewMsgRevisionId JS global for logged in users. This will be null
83 if the user has no new talk page messages. Otherwise it will be set to the
84 revision ID of the oldest new talk page message. This will allow gadgets and
85 extensions to create their own new message alerts on the client side.
86 * mediawiki.log: Added log.warn wrapper (uses console.warn and console.trace).
87 * mediawiki.log: Implemented log.deprecate. This method defines a property and
88 uses ES5 getter/setter to emit a warning when they are used.
89 * $wgCascadingRestrictionLevels was added, allowing one to specify restriction levels
90 which can be cascading (previously 'sysop' was hard-coded as the only one).
91 * XHTML5 support has been improved. If you set $wgMimeType = 'application/xhtml+xml'
92 MediaWiki will try outputting markup acording to XHTML5 rules.
93 * New hook 'TitleSquidURLs' for manipulating the list of URLs to be purged from
94 HTTP caches when a page is changed.
95 * Changed the patrolling system to always show the link for patrolling in case the
96 current revision is patrollable. This also removed the usage of the rcid URI parameters.
97 * Oracle DB backend now supports Database Resident Connection Pooling (DRCP).
98 Can be enabled by setting $wgDBOracleDRCP=true.
99 Requires Oracle DB 11gR1 or above, enabled DRCP inside the DB itself and a
100 propper connect string.
101 More about DRCP can be found at:
102 http://www.oracle-base.com/articles/11g/database-resident-connection-pool-11gr1.php
103 * Add a new parameter $patrolFooterShown to hook ArticleViewFooter so the hook
104 handlers can take further action based on the status of the patrol footer
105 * LinkCache singleton can now be altered or cleared, letting one to specify
106 another instance that does not rely on a database backend.
107 * MediaWiki's PHPUnit tests can now use PHPUnit installed using composer --dev.
108 * New user rights have been added to increase granularity in rights management
109 for extensions such as OAuth:
110 ** editmyusercss controls whether a user may edit their own CSS subpages.
111 ** editmyuserjs controls whether a user may edit their own JS subpages.
112 * Add new hook AbortTalkPageEmailNotification, this will be used to determine
113 whether to send the regular talk page email notification
114
115 === Bug fixes in 1.22 ===
116 * Disable Special:PasswordReset when $wgEnableEmail is false. Previously one
117 could still navigate to the page by entering the URL directly.
118 * (bug 47138) Fixed a fatal error when a blocked user tries to automatically
119 create an account on login due external authentication in some circumstances.
120 * (bug 23393) HTML <hN> headings containing line breaks are now handled
121 correctly.
122 * (bug 45803) Whitespace within == Headline == syntax and within <hN> headings
123 is now non-significant and not preserved in the HTML output.
124 * (bug 47218) Special:BlockList now handles correctly user names with spaces
125 when passed as subpage.
126 * Pager's properly validate which fields are allowed to be sorted on.
127 * mw.util.tooltipAccessKeyRegexp: The regex now matches "option-" as well.
128 Support for Mac "option" was added in 1.16, but the regex was never updated.
129 * (bug 46768) Usernames of blocking users now display correctly, even if numeric.
130 * (bug 39590) {{PAGESIZE}} for the current page and self-transclusions now
131 show the most up to date result always instead of being a revision behind.
132 * A bias in wfRandomString() toward digits 1-7 has been corrected. Generated
133 strings will now start with digits 0 and 8-f as often as they should.
134 * (bug 45371) Removed Parser_LinkHooks and CoreLinkFunctions classes.
135 * (bug 41545) Allow <kbd>, <samp>, and <var> to be nested like allowed in html.
136 * PLURAL magic word no longer causes a PHP notice when no matching form exists.
137 * (bug 36641) Patrol page links no longer show on non-existent revisions.
138 * (bug 35810) Pages not linked from Special:RecentChanges or Special:NewPages
139 are patrollable now.
140 * (bug 30213) JavaScript for search suggestions is now disabled when the API
141 is disabled, and AJAX patrolling and watching are now disabled when use of
142 the write API is not allowed.
143 * (bug 48294) API: Fix chunk upload async mode.
144 * (bug 46749) Broken files tracking category removed from pages if an image
145 with that name is uploaded.
146
147 === API changes in 1.22 ===
148 * (bug 46626) xmldoublequote parameter was removed. Because of a bug, the
149 parameter has had no effect since MediaWiki 1.16, and so its removal is
150 unlikely to impact existing clients.
151 * (bug 47216) action=query&meta=siteinfo&siprop=skins will now indicate which
152 skin is the default and which are unusable (e.g. listed in $wgSkipSkins).
153 * (bug 25325) Added support for wlshow filtering (bots/anon/minor/patrolled)
154 to action=feedwatchlist.
155 * WDDX formatted output will actually be formatted (and normal output will no
156 longer be), and will no longer choke on booleans.
157 * action=opensearch no longer silently ignores the format parameter.
158 * action=opensearch now supports format=jsonfm.
159 * list=usercontribs&ucprop=ids will now include the parent revision id.
160 * BREAKING CHANGE: action=parse no longer returns all langlinks for the page
161 with prop=langlinks by default. The new effectivelanglinks parameter will
162 request that the LanguageLinks hook be called to determine the effective
163 language links.
164 * BREAKING CHANGE: list=allpages, list=langbacklinks, and prop=langlinks do not
165 apply the new LanguageLinks hook, and thus only consider language links
166 stored in the database.
167 * (bug 47219) Allow specifying change type of Wikipedia feed items
168 * prop=imageinfo now allows setting iiurlheight without setting iiurlwidth
169 * prop=info now adds the content model and page language of the title.
170 * New upload log entries will now contain information on the relavent
171 image (sha1 and timestamp).
172 * (bug 49239) action=parse now can parse in preview mode.
173 * (bug 49259) action=patrol now accepts revision ids.
174
175 === Languages updated in 1.22===
176
177 MediaWiki supports over 350 languages. Many localisations are updated
178 regularly. Below only new and removed languages are listed, as well as
179 changes to languages because of Bugzilla reports.
180
181 * Batak Toba (bbc-latn) added.
182 * (bug 46751) Made Buryat (Russia) (буряад) (bxr) fallback to Russian.
183
184 === Other changes in 1.22 ===
185 * redirect.php was removed. It was unused.
186 * ClickTracking integration was dropped from the mediaWiki.user.bucket
187 JavaScript function. The 'tracked' option is now ignored.
188 * BREAKING CHANGE: Legacy skins Simple, MySkin, Chick, Standard and Nostalgia
189 were all removed. (Nostalgia was moved to an extension.) The SkinLegacy and
190 LegacyTemplate classes that supported them were removed as well and are now a
191 part of the Nostalgia extension.
192 * Event namespace used by jquery.makeCollapsible has been changed from
193 'mw-collapse' to 'mw-collapsible' for consistency with the module name.
194 * BREAKING CHANGE: The "ExternalAuth" authentication subsystem was removed, along
195 with its associated globals of $wgExternalAuthType, $wgExternalAuthConf,
196 $wgAutocreatePolicy and $wgAllowPrefChange. Affected users are encouraged to
197 use AuthPlugin for external authentication/authorization needs.
198 * The Quickbar feature of the legacy skin model and the last remnants of it
199 throughout the code base have been removed.
200 * Externaledit/externaldiff preference was removed. Very few users used this
201 feature, and improper configuration can actually prevent a user from editing
202 * Calling Linker methods using a skin will now output deprecation warnings.
203 * (bug 46680) "Return to" links are no longer tagged with rel="next".
204 * BREAKING CHANGE: mw.util.tooltipAccessKeyRegexp: The match group for the
205 accesskey character is now $6 instead of $5.
206 * HipHop compiler (hphpc) support was removed. HipHop VM support (hhvm) was
207 added.
208 * A new Special:Redirect page was added, providing lookup by revision ID,
209 user ID, or file name. The old Special:Filepath page was reimplemented
210 to redirect through Special:Redirect.
211 * Monobook: Removed the old conditional stylesheets for Opera 6, 7 and 9.
212 * Support for XHTML 1.0 has been removed. MediaWiki now only outputs (X)HTML5.
213 * wikibits: User-agent related globals have been deprecated. The following
214 properties now default to false and emit mw.log.warn: is_gecko, is_chrome_mac,
215 is_chrome, webkit_version, is_safari_win, is_safari, webkit_match, is_ff2,
216 ff2_bugs, is_ff2_win, is_ff2_x11, opera95_bugs, opera7_bugs, opera6_bugs,
217 is_opera_95, is_opera_preseven, is_opera, and ie6_bugs.
218 * (bug 48276) MediaWiki will now flash a confirmation message upon successfully
219 editing a page.
220 * (bug 40785) mediawiki.legacy.ajax has been marked as deprecated. The following
221 properties now emit mw.log.warn when accessed: sajax_debug, sajax_init_object,
222 sajax_do_call and wfSupportsAjax.
223 * BREAKING CHANGE: meta keywords are no longer supported. A <meta name="keywords"
224 will no longer be output and OutputPage::addKeyword no longer exists.
225 * Methods Title::userCanEditCssSubpage and Title::userCanEditJsSubpage,
226 deprecated since 1.19, have been removed.
227
228 == Compatibility ==
229
230 MediaWiki 1.22 requires PHP 5.3.2 or later.
231
232 MySQL is the recommended DBMS. PostgreSQL or SQLite can also be used, but
233 support for them is somewhat less mature. There is experimental support for
234 Oracle.
235
236 The supported versions are:
237
238 * MySQL 5.0.2 or later
239 * PostgreSQL 8.3 or later
240 * SQLite 3.3.7 or later
241 * Oracle 9.0.1 or later
242
243 == Upgrading ==
244
245 1.22 has several database changes since 1.21, and will not work without schema
246 updates. Note that due to changes to some very large tables like the revision
247 table, the schema update may take quite long (minutes on a medium sized site,
248 many hours on a large site).
249
250 If upgrading from before 1.11, and you are using a wiki as a commons
251 repository, make sure that it is updated as well. Otherwise, errors may arise
252 due to database schema changes.
253
254 If upgrading from before 1.7, you may want to run refreshLinks.php to ensure
255 new database fields are filled with data.
256
257 If you are upgrading from MediaWiki 1.4.x or earlier, you should upgrade to
258 1.5 first. The upgrade script maintenance/upgrade1_5.php has been removed
259 with MediaWiki 1.21.
260
261 Don't forget to always back up your database before upgrading!
262
263 See the file UPGRADE for more detailed upgrade instructions.
264
265 For notes on 1.21.x and older releases, see HISTORY.
266
267 == Online documentation ==
268
269 Documentation for both end-users and site administrators is available on
270 MediaWiki.org, and is covered under the GNU Free Documentation License (except
271 for pages that explicitly state that their contents are in the public domain):
272
273 https://www.mediawiki.org/wiki/Documentation
274
275 == Mailing list ==
276
277 A mailing list is available for MediaWiki user support and discussion:
278
279 https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
280
281 A low-traffic announcements-only list is also available:
282
283 https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce
284
285 It's highly recommended that you sign up for one of these lists if you're
286 going to run a public MediaWiki, so you can be notified of security fixes.
287
288 == IRC help ==
289
290 There's usually someone online in #mediawiki on irc.freenode.net.