aboutsummaryrefslogtreecommitdiffstats
path: root/includes/specials/SpecialBlock.php
Commit message (Collapse)AuthorAgeFilesLines
* Fixup some returns/return documentationSam Reed2012-01-031-1/+1
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/107889
* Use local context to get messagesAlexandre Emsenhuber2011-12-281-7/+7
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/107510
* (bug 33156) Special:block didn't let you confirm blocking yourself if using ↵Brian Wolff2011-12-201-2/+6
| | | | | | | | | | non-normalized name. Was comparing the normalized name to the non-normalized name that gets inserted into the form, since request variables from previous request override form defaults. Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/106774
* Bug 29524 - Rename RequestContext::getLang to getLanguageJohn Du Hart2011-11-211-1/+1
| | | | | | | I'll be amazed if this doens't break any tests. Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/103817
* Comments, braces, explicit member variablesSam Reed2011-11-161-1/+0
| | | | | | | Remove a couple of unused variables Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/103323
* Convert SpecialBlock to subclass FormSpecialPageJohn Du Hart2011-11-151-62/+82
| | | | | | | Also fixes the problem introduced in r103115 Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/103123
* Updated core SpecialPages to use new functions introduced in r103111 and r103095John Du Hart2011-11-151-11/+2
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/103115
* Removed usage of $wgUser in block and unblock processing:Alexandre Emsenhuber2011-11-131-28/+37
| | | | | | | | | * Made HTMLFormField pass the HTMLForm object to the validation and filter callbacks (so that they can get a context) * Added new parameter to SpecialBlock::checkUnblockSelf() to pass the user doing the request * SpecialBlock::processForm() and SpecialUnblock::processUnblock() now require a context as second parameter; added SpecialBlock::processUIForm() and SpecialUnblock::processUIUnblock() as adaptators from HTMLForm as second parameter to context Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/102879
* Per Nikerabbit's comment on r100621:Alexandre Emsenhuber2011-10-271-2/+2
| | | | | | | | | | * Removed OutputPage::setPageTitleMsg() and OutputPage::setHTMLTitleMsg() and make OutputPage::setPageTitle() and OutputPage::setHTMLTitle() accept a Message object * Updated core calls (including some that I missed last time because of non-matching case) * Added Message::setContext() and use it in RequestContext so that I don't need to duplicate the call in OutputPage * Yes, I'm calling $this->msg() on places and then setting the context one more time in OutputPage::setPageTitle() or OutputPage::setHTMLTitle(), but at least I won't be confused about which objects $ Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/101037
* Added OutputPage::setPageTitleMsg() and OutputPage::setHTMLTitleMsg() as ↵Alexandre Emsenhuber2011-10-241-2/+2
| | | | | | | modified versions of OutputPage::setPageTitle() and OutputPage::setHTMLTitle() that take an message name and its parameters; updated all calls in core that can use the two new functions Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/100621
* Don't add 'autoblock disabled' flag for IP range blocksAaron Schulz2011-10-061-2/+2
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/99161
* Fixed:Aaron Schulz2011-10-051-1/+1
| | | | | | | Undefined index: IPV6 in D:\www\MW_trunk\phase\includes\specials\SpecialBlock.php on line 516 Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/98975
* Fixed bogus addModules() call which broke the JS on the block form (didn't load)Aaron Schulz2011-10-011-1/+1
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/98610
* (bug 31206) "Altering blocks doesn't appear to be working". Don't compare ↵Aaron Schulz2011-09-281-1/+1
| | | | | | | string to User objects :) Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/98298
* Allow LogEventsList::showLogExtract() to get a Title object instead of ↵Alexandre Emsenhuber2011-09-241-2/+2
| | | | | | | having to do Title -> string -> Title conversion Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/98012
* Added missing calls to SpecialPage::setHeaders() and SpecialPage::outputHeader()Alexandre Emsenhuber2011-09-211-0/+3
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/97707
* * Use local context instead of global variables (where possible)Alexandre Emsenhuber2011-09-121-28/+26
| | | | | | | * Made getFormFields() non-static since the only call to it is in that file Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/96828
* Add some full message keys as they originate from these locations.Siebrand Mazeland2011-09-011-0/+6
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/95991
* w/sSiebrand Mazeland2011-09-011-9/+24
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/95987
* Followup r85025, r85166, r93233: use strict comparison per CR comment, ↵Roan Kattouw2011-08-111-1/+1
| | | | | | | because "0" != "00" is false Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/94235
* * Fix double-escaping from r85025Happy-melon2011-07-261-7/+13
| | | | | | | * Allow admins to modify blocks placed (probably accidentally) on themselves *by* themselves, whether or not they have the 'unblockself' permission. Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/93233
* Fix inaccurate return type in commentAryeh Gregor2011-07-201-1/+1
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/92607
* * Use standard method to check user permissionsAlexandre Emsenhuber2011-07-161-6/+6
| | | | | | | | * Directly throw an ReadOnlyError instead of calling OutputPage::readOnlyPage() * In Special:Block: don't let user think the error is temporary if he doesn't have right and the database is locked, instead check permissions first and then the database lock Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/92377
* Change usages of $wgUser->getSkin() in special pages to use $this->getSkin()Sam Reed2011-07-011-1/+1
| | | | | | | Fix trailing whitespace Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/91246
* Code style cleanups, use strict comparison with $data['PreviousTarget'] per CRAaron Schulz2011-06-241-2/+5
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/90693
* Follow-up r90371, per comment by ^demonMatěj Grabovský2011-06-201-1/+2
| | | | | | | Escape wikitext in username before passing it to certain messages; also remove <nowiki>s in those as they're superfluous. Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/90482
* w/s changes.Mark A. Hershberger2011-06-021-1/+1
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/89356
* PreviousTarget is now optional when blocking a userAntoine Musso2011-05-291-1/+1
| | | | | | | | The API does not seem to give a PreviousTarget field all the time. This patch also fix the an assertion for ApiBlockTest::testMakeNormalBlock Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/89087
* DB_READ -> DB_SLAVE, the former is obsoleteAlexandre Emsenhuber2011-05-181-1/+1
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/88384
* Use consistent notation for "@todo FIXME". Should update ↵Siebrand Mazeland2011-05-171-1/+1
| | | | | | | http://svn.wikimedia.org/doc/todo.html nicely. Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/88355
* Follow-up r83795: fix E_NOTICE due to undefined array member.Happy-melon2011-05-021-1/+1
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/87272
* Look mum, no globals! Implement a RequestContext for HTMLForm, passed in ↵Happy-melon2011-04-131-2/+1
| | | | | | | the constructor. Currently this is optional with B/C; at a later date it should be made compulsory. Doing this removes the need to call $form->setTitle() on every single use; only when you want to set the title to something other than the page context title. Implemented the new syntax in a sample of forms. Also fix a few minor errors in HTMLForm.php that my IDE complained about. Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/85957
* Follow-up r85025: fix the you're-trying-to-block-yourself-you-twit warning, ↵Happy-melon2011-04-011-18/+84
| | | | | | | and make it an actual checkbox confirmation. Also use said confirmation for reblocks, and HideUser (bug 18678). Mark a static function from HTMLForm which is called from SpecialBlock as explicitly public. Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/85166
* Follow-up r85025 - use strict comparisonHappy-melon2011-03-301-1/+1
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/85042
* (bug 23408) give admins a warning before letting them block themselves. ↵Happy-melon2011-03-301-2/+14
| | | | | | | Also tweak the logic so that loading the interface for one already-blocked user, then actually submitting a block on a different user, shows the confirmation again if the second user is already blocked. Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/85025
* Fix "$1 is already blocked" parameter-not-passed-to-message errorHappy-melon2011-03-221-2/+2
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84538
* Fixed daft error in r84523 so "angry" autoblocks work againAaron Schulz2011-03-221-4/+1
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84525
* Relate block log entries to block table rows (useful for bug 25763)Aaron Schulz2011-03-221-7/+10
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84523
* Follow-up r84475: fix notices.Happy-melon2011-03-221-0/+4
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84522
* Blame hashar for this giant commit; he teased me for making so many smaller ↵Happy-melon2011-03-211-23/+17
| | | | | | | | | | | | | | | ones earlier... :D * Internalise $mAddress/$mUser, $mBy/$mByName, $mEnableAutoblock, $mId as getTarget(), getBlockers(), isAutoblocking(), getId(). * This required editing AbuseFilter and CheckUser backwards-incompatibly, so push the rest of the changes out to those extensions. * Attack the evil 14-parameter constructor and gratuitously-confusing newFromDB( $notVeryImportantParameter, $moreImportantParameter) * Reimplement the hack for bug 13611 in a slightly less fragile fashion; could still do with further cleanup, but then again the login frontend is its own can of worms... :S * Remove transitionary getTargetAndType() and newFromTargetAndType() methods * Some optimisation in parseTarget() * Fix the broken phpunit test mentioned in r84251 Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84475
* Follow-up r84358 CR: rename 'editusertalk' to 'editownusertalk', private --> ↵Happy-melon2011-03-201-2/+2
| | | | | | | protected, and run stylize.php over Block.php Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84406
* * Implement an extensible Block::prevents( <action> ) function to replace ↵Happy-melon2011-03-191-13/+10
| | | | | | | | | | | the plethora of direct member variable accesses This pushes the historic *disable*-createaccount-vs-*allow* usertalk-edit wierdness down to the database layer * Implement accessors for isHardblock() and getRangeStart()/getRangeEnd() in the same fashion. * Make the corresponding variables private, removing external accessors. This required updating AbuseFilter with non-B/C code, so I also implemented the rest of the changes I've made to the blocking backend in that extension. * Move the "get an IP range which encompasses the given IP/range" logic to Block.php; will be needed later... :D Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84358
* Follow-ups to r84258Happy-melon2011-03-181-2/+6
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84279
* w/s diff. mostly eol w/s and using only tabs of width 4 to indent.Mark A. Hershberger2011-03-181-4/+4
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84262
* First forays into the swamp of the Block.php backend:Happy-melon2011-03-181-10/+35
| | | | | | | | * Move Block::parseExpiryInput() to the frontend SpecialBlock::parseExpiryInput() * consolidate the several implementations of the MediaWiki:Ipblockoptions parsing into SpecialBlock::getSuggestedDurations() Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84251
* Fix typo in r83786Happy-melon2011-03-171-1/+1
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84195
* Fix notice from TWN, reported in r83786 CRHappy-melon2011-03-151-1/+1
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84028
* Fix exception on TWN raised in r83855 CR.Happy-melon2011-03-151-3/+9
| | | | Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/84006
* Complete the trinity of blocking frontend interfaces by rewriting ↵Happy-melon2011-03-141-1/+1
| | | | | | | | | | | | | SpecialIpblocklist: * Move and rename to SpecialBlockList * Use an HTMLForm in GET mode for the options form * Use TablePager to organise the results more nicely * Standardise the filtration for IPs and IP ranges, so looking at blocks for a range will now also show rangeblocks which contain the range * General tidy up Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/83909
* Further massive rewrite of the blocking frontend: spin out unblocking into a ↵Happy-melon2011-03-131-5/+4
| | | | | | | new SpecialUnblock.php. This leaves IPBlockList as, astonishingly enough, a list of blocks... :D Notes: http://mediawiki.org/wiki/Special:Code/MediaWiki/83855