Commit graph

274 commits

Author SHA1 Message Date
umherirrender
89c92dbac7 Fixed some @params documentation (includes/[Article|Pref|Skin].php)
Swapped some "$var type" to "type $var" or added missing types
before the $var. Changed some other types to match the more common
spelling. Makes beginning of some text in captial.

Change-Id: I6627ba0e76d3577c40bf2473e0f78a5ad7368634
2014-04-23 11:46:22 +02:00
jenkins-bot
d16f223edf Merge "Removed 'Remember my login' preference" 2014-04-17 17:02:43 +00:00
tonythomas01
74756a2409 Removed 'Remember my login' preference
Removed 'Remember my login' from Preferences, as it was unwanted. It adds
to the complexity of the user preferences

Bug: 52342
Co-Author: Tyler Romeo <tylerromeo@gmail.com>
Change-Id: I7c957e1e1aaecf47f7c47bc063b5d3b364644afc
2014-04-16 12:49:44 +05:30
Bartosz Dziewoński
59002d8935 Consistently use '@deprecated since <version>'
Variants included 'in <version>', 'as of <version>' and just the
version number.

Some @deprecated annotations do not have the version number at all,
I want to hunt them down separately.

Change-Id: I8208c6097098f4735d4f51bc42254675f1f27f6d
2014-04-15 22:18:19 +02:00
jenkins-bot
83a1cf573f Merge "Rename Skin::getUsableSkins() to Skin::getAllowedSkins()" 2014-04-13 00:30:53 +00:00
Tony Thomas
a3ffeffe18 Moved "Date format" user preference to "Appearance" tab
This user preference affects the appearance of the site,
so this feels like a natural fit

Bug: 63582
Change-Id: Ib97b1b39723f1835b7f6086ff1418ab5de13a7a1
2014-04-11 13:09:51 +00:00
umherirrender
ad69935c0b fix typo in comment in Preferences.php
The name of the preference was spelled wrong.

Change-Id: I443d0a8fc67c89da36b5c725dd3f3513d4170357
2014-04-05 19:18:12 +00:00
jenkins-bot
7a74e085d9 Merge "Preferences.php: avoid "Undefined index" if key 'realname' don't exist in $formdata" 2014-03-19 22:53:31 +00:00
jenkins-bot
c2665e4b6e Merge "Remove user preference "noconvertlink"" 2014-03-11 10:01:16 +00:00
gbt248
7110eb061a Preferences.php: avoid "Undefined index" if key 'realname' don't exist in $formdata
Added additional check for missing key "realname" in $formData which can cause
an undefined index: realname

Bug: 62029
Change-Id: I6763c12d9b4d8b1e574eb3162168f4f5380df93a
2014-03-02 23:40:05 +01:00
tonythomas01
11c04f9ecb Removed 'Enable simplified search bar (Vector skin only)' from MW user Preference
The vector-simplesearch preference is enabled by default since version 1.22.
The option is removed to decrease the clutter in the preference page

Bug: 52815
Change-Id: I6d8dd997a4c4a6b8fb06b4674dda5f306432c6af
2014-02-19 17:53:55 +01:00
Liangent
333bf3ae5b Remove user preference "noconvertlink"
This toggle was introduced in 8d06ad6e, but the most useful feature for
human users there (disabling <h1> conversion on a per-user basis) has
been dropped due to cache fragmentation. The only remaining part is not
quite useful and can be covered by the URL parameter &linkconvert=no.

Change-Id: I12f2cdc9b0d44d6e47487b14fa8ef010de5c94a7
2014-02-08 03:10:16 +00:00
jenkins-bot
afb954e890 Merge "Remove unused $entryPoint from Preferences::tryFormSubmit" 2014-02-06 16:51:49 +00:00
jenkins-bot
11cb289cfc Merge "API: Handle "special" options in action=options" 2014-02-04 18:43:40 +00:00
jenkins-bot
68e8c6ca53 Merge "Add PreferencesFormPreSave hook" 2014-02-03 03:00:44 +00:00
Marius Hoch
fe565ce25f Remove unused $entryPoint from Preferences::tryFormSubmit
Change-Id: Ied5f81df70061fecb09bfb85174c9868c8828bbf
2014-02-03 04:00:05 +01:00
tonythomas01
2f9cfa3d26 Removed "Justify paragraphs" from MW user Preference.
Removed the option 'Justify paragraphs' from MW Preferences
as it is not a necessary option there.
Added RELEASE NOTES.

Bug: 52810
Change-Id: I1fe6a5857070828726077e6ba229b786c017c858
2014-01-25 09:57:57 +05:30
tonythomas01
aadd16aab1 Remove preference "Show table of contents (for pages with more ...)"
The table of contents box is auto-inserted, can trivially be hidden or
exposed on a per-page basis with __MAGICWORDS__, includes a sticky
[show|hide] link, and can be easily hidden with site-wide CSS as
necessary. It needlessly adds complexity and user interface clutter.

Bug: 52813
Change-Id: If2139317dae4aa980b373c73d7b81dac627b5af8
2014-01-24 12:59:44 -08:00
tonythomas01
f6aa7b3e88 Removed "Enable section editing via [edit] links" from preferences
Unwanted user preference option in MW adding to the clutter.
Users interested in hiding section-edit links can use per-user
(or site-wide) CSS.
Removed 'editsection' from Defaultsettings.php and
ResourceLoaderUserCSSPrefsModule.php
Updated Release Notes

Bug: 52811
Change-Id: I5fc49106621943ca7180ddb37590b624edac67d5
2014-01-25 00:04:40 +05:30
Kunal Mehta
266e9d91d1 Add PreferencesFormPreSave hook
Allows extensions to modify what preferences will be saved

Change-Id: Ibd8331c39afdde39b688d78f3faade2883f0c997
2014-01-23 23:53:16 +00:00
umherirrender
17aa87d651 Remove outdated comment from Preferences.php
There is a cleanupPreferences.php script

Change-Id: I29c55b3ba5d296a06e3c26e98b28779cb3959282
2014-01-19 21:41:33 +01:00
jenkins-bot
15cb0501f6 Merge "Remove "or other" option for stubtreshold" 2014-01-08 21:31:11 +00:00
Chad Horohoe
f5e7453f5c Remove searchlimit preference
Change-Id: Ib3dd2ba54261514b827d12a21536392530c7e02e
2014-01-07 17:48:35 -08:00
Chad Horohoe
f3d8cc92a5 Remove "or other" option for stubtreshold
People use this to set it to absolutely insane values.

Enwiki-Stats: http://p.defau.lt/?1j4omOrfCZzQvIJ_z_dOEQ
Change-Id: I88212703c69d0540f3134f661beee6c1428932a9
2013-12-26 02:49:51 -05:00
Amir E. Aharoni
46cf6929ed Clean some phpcs errors in Preferences.php
Change-Id: I315e562c5f85e464a8ca61be6a47e2a468156a55
2013-12-15 09:20:11 +02:00
01tonythomas
3f0b8c88c3 Removed 'Disable browser page caching" user preference
It is  a very advanced user preference with little usage and is often misleading.
Updated Release Note.

Bug: 52809
Change-Id: I43f6205df53c7a38717c60a2d7d144307feb58a4
2013-12-07 14:02:44 +05:30
tonythomas01
3d17f0dabf Removed "Disable search suggestions" from Mediawiki Preference
It's rarely used and provide more interface clutter and code complexity than
any benefit it provides.

Bug: 52812
Change-Id: I4b1d243b1b1a9da484147c4a682f44aa08a22803
2013-12-05 09:34:02 +05:30
umherirrender
0bc583af2c Move closing parenthesis from multi line if and function to own line
The Line continuation Coding conventions prefers the closing parenthesis
on the same line than the beginning curly braces. This is done for ifs
and functions.
Also move some boolean operator from the end of a line to the beginning
and changed some indentation to make the condition hopefully better
readable.

Change-Id: Id0437b06bde86eb5a75bc59eefa19e7edb624426
2013-12-01 21:39:00 +01:00
Brad Jorsch
b393835bda API: Handle "special" options in action=options
There are certain preferences, such as realname and emailaddress, that
are handled specially in Special:Preferences and are not accessible by
User::getOptions or User::setOptions. But action=options was allowing
a 'dummy' version to be set in User::setOptions.

Change-Id: I4c1b3d8e1eae9520228d7b6da9c41ada80f7c387
2013-10-10 11:02:04 -04:00
jenkins-bot
a71728c990 Merge "Remove "Misc" tab from Special:Preferences" 2013-09-12 19:22:15 +00:00
Federico Leva
291db2aeb0 Clarify "unknown gender" option is a non-answer and resort
It is easier in other languages, but in English some worry
about "I prefer not to detail" not being an answer to the
question used as label of the option; parentheses should
be enough to clarify it is about not answering the question
because you don't care.

Also put such (default) "zero answer" first and move feminine
before male as suggested by Jared to avoid any appearance of
bias in the user interface, though the fallback works that way
in the code anyway for merely grammatical reasons.

Bug: 53311
Bug: 53834
Change-Id: Iea77e903c91063a648fff5e4be41c0be51ac172a
2013-09-06 13:24:17 +02:00
jenkins-bot
57f156a8a1 Merge "doc: Remove repetitive "Give grep a chance" phrase from comments" 2013-08-29 20:32:38 +00:00
Timo Tijhof
90749a261c doc: Remove repetitive "Give grep a chance" phrase from comments
* Follows-up b2e2b2e016.
* Minor clean up of surrounding documentation comments.
* Fixed missing keys for messages in WebInstallerPage

Change-Id: Iaa692064262f3c0e10cfa5e4b1ec8c86e5d02362
2013-08-29 10:46:46 -07:00
Chad Horohoe
7b3898a74c Add help message to prefershttps
The preference requires logging back in again to set the new cookies.

Change-Id: I2602205eec752c927ac6df81545e69f5c9e70ee4
2013-08-28 11:57:57 -07:00
jenkins-bot
d8b36ec22b Merge changes I7493a329,Iaa9dd210
* changes:
  Only show prefershttps if IP can use HTTPS
  Core support for disabling HTTPS based on GeoIP
2013-08-23 20:29:38 +00:00
Chad Horohoe
9e7693c749 Only show prefershttps if IP can use HTTPS
Change-Id: I7493a329d35fad3f17aac2df935f4f9306828884
2013-08-23 12:34:06 -07:00
Chad Horohoe
c8272b3969 Default is not necessary for toggle fields
Change-Id: Ia11290431bc19905f744b65b001adc53c023e2ca
2013-08-22 10:42:19 -07:00
Amir E. Aharoni
90b0ef0098 Try to improve the wording of gender option
* Move the gender option to the internationalisation section,
  because it's mostly used for that.
* Change the displayed values: rather then gender identifiers,
  it demonstrates the usage of the option.
* Update documentation accordingly.

Change-Id: I81f02f03f5992ad5f0501e0a7552bdee9f2c1d5e
Bug: 31816
2013-08-21 09:10:50 +00:00
Tyler Anthony Romeo
374a0ad943 Change secure login to use a user preference
Removed the wpStickHTTPS checkbox from the login form, and instead
just use the user's preferences along with whether they came from
HTTPS or not to determine if they should stay in HTTPS.

Bug: 29898
Bug: 52283
Change-Id: I69e9cb23b8d700e821b8a961c672958e4e19e4f8
2013-08-19 16:57:04 -07:00
shirayuki
b2e2b2e016 Give grep a chance to find the usages
Change-Id: I18846326539b814fa7fa93ca54117dac3572e4b0
2013-08-16 22:07:38 +09:00
Liangent
3a06dd9be9 Allow more than one variant set in user preferences.
Now with the introduction of page language, a site can have pages
in all languages, and different languages have different variants.
This patch allows users to set preferred variants for every page
they may see on the site.

Change-Id: Ie7e82bee0b1f8f902b38bb4a464cf0ebc4df4d89
2013-08-16 05:46:14 +00:00
MatmaRex
8dd562d4da Remove "Misc" tab from Special:Preferences
It has served us faithfully for many years, but now, after most of its
contents have been moved to other tabs, it only contained one section
with two options related to diffs in it. Moved these two as well to
"Appearance" tab where they rightfully belong.

Also moved some code potentially adding items to the personal/i18n
section out of the misc part and to the personal part, where it should
have always been in the first place. (This actually appears to be dead
code, as $extraUserToggles doesn't seem to be defined for any language
- marked as FIXME.)

The Preferences::miscPreferences() function doesn't do anything now,
but kept it and its only call just in case for backwards-compatibility.

Bug: 52084
Change-Id: I537abc9884e18acf3ff9a425241de4607dfd7c33
2013-08-12 20:45:53 +00:00
Daniel Friesen
13b1a9f832 Remove the showjumplinks user preference
This preference does not appear to have a valid purpose.  Jump links are
part of accessibility, sites must never force users to turn this on.

For logged in users there is no value in removing the links.  They take up
practically no space in the markup, and that would be a dubious reason.
And these links are not even visible so users should have no reason to be
bothered by them.

Change-Id: Ib506ffad41ac7f65629368bc41774fb689b882db
2013-07-31 22:30:46 +02:00
Alexandre Emsenhuber
88a8773c49 Follow-up I3f03dd0100 (08adf46): simplify checks
Those variables are only used when $canViewPrivateInfo is true;
so no need set them when it is not the case

Change-Id: I87a27ea94f3eadc757b6e6048437a7ec58d09d03
2013-07-25 17:51:41 +02:00
MatmaRex
ed7979a970 Refactor watchlist token handling
Do not allow the user to change it directly; instead create a form
where they can reset it. (The token can still be changed via the API.)
The token is autogenerated whenever it is shown or otherwise used.

This really should have never used the preferences; however, trying to
change that now would be lots of work for very little gain, so this
keeps using that mechanism, adding a little abstraction over it.

It's not unconceivable that similar tokens could be used for other
pieces of data, like Echo's notifications; this enables that with one
new hook.

----

Things done here:

* Add getTokenFromOption() and resetTokenFromOption() methods to User,
  abstracting out the get-and-generate-if-empty process of handling
  tokens. Respect $wgHiddenPrefs (Watchlist didn't do that
  previously).

* Create Special:ResetTokens, inspired by Special:Preferences and
  Special:ChangeEmail, presenting the token resetting interface
  (HTMLForm-based with CSRF protection).

* Create a new hook, SpecialResetTokensTokens, allowing extensions to
  register tokens to be shown in the resetting form. Each token needs
  information about the preference it corresponds to and a short
  description (used for checkbox label).

* Hide the preference on Special:Preferences (use type=api to achieve
  this), display a link to aforementioned special page instead. Move
  info blurb to its own section at the bottom.

Bug: 21912
Change-Id: I0bdd2469972c4af81bfb480e9dde58cdd14c67a8
2013-07-24 22:06:15 +02:00
umherirrender
0a810a5a87 Avoid date()/gmdate() for date formatting
Added a MWTimestamp::format method to format a timestamp object in the
given pattern. This avoids date(), which needs the local time
zone corretly set on the server, which is assumed at the moment in
Setup.php

Added MWTimestamp::getInstance for gmdate() and
MWTimestamp::getLocalInstance for date() to create a MWTimestamp object
and use it as inline statement.
Also MWTimestamp::setTimezone and MWTimestamp::getTimzone was added for
timezone handling.

Change-Id: I812aa013be2f4380e0cf10dc465202756fe8347b
2013-07-08 04:14:12 +00:00
Brad Jorsch
08adf46b26 Add 'viewmyprivateinfo', 'editmyprivateinfo', and 'editmyoptions' rights
These are needed for OAuth grants.

Note that we don't bother with a 'viewmyoptions' right, since the
majority will be determinable from just observing the interface.

Note that the fact of having a confirmed email address cannot be
reliably hidden, and if the user has 'sendemail' they may be able to
determine the real name and email address by sending an email to another
account that they control.

Change-Id: I3f03dd010020e8d43cc2d3bca7b3ef7196d1c548
2013-07-03 13:40:04 -04:00
TMg
08de49eb88 Re-grouping and ordering the editing preferences
Arange the settings in three groups: How to call the editor, how
the editor looks and how the preview works. The only toolbar
preference is at the bottom because the WikiEditor extension adds
its stuff there. All the preferences are untouched. This does not
add or remove a preference.

Goes with Id8b9a47a in the WikiEditor extension.

Change-Id: I429c8125b8db789d2756d61249f6cf1fa7f2f51c
2013-06-30 15:46:56 +02:00
Waldir Pimenta
bf82e8d0f1 Rename Skin::getUsableSkins() to Skin::getAllowedSkins()
Follow-up to change 65426 (commit a3c7a8b8f)

Also, rewrite the documentation for this function call in Preferences.php
To remove the "(skins is all skin names from Language.php)"
which I couldn't make sense of.

Change-Id: I0b0fdfb5615c22aa876882c3ca344ebb1f10c4bd
2013-05-26 11:53:58 +02:00
Michał Zieliński
c143ab00dd Preferences: Add link to user contributions on value of "Number of edits".
Bug: 43637
Change-Id: I10a662051fc23ff007b8749c4dc46a4b53a7f4bd
2013-05-24 21:18:34 +02:00