Commit graph

76 commits

Author SHA1 Message Date
Brion Vibber
51fb6ae2bf * (bug 5817) Special:Recentchangeslinked now shows red link for nonexistent target page instead of silently redirecting. 2007-03-29 14:25:07 +00:00
Brion Vibber
11c3c96411 Revert r14063; listed as fix for bug 5817 in May 2006 but the behavior seems very unintuitive to me.
The listed problem is that the backlink to the target page on Special:Recentchangeslinked shows blue for nonexistent pages, but this patch made it redirect to the nonexistent page, where I'd expect to just change the link coloring. The redirect behavior also makes it tough to work with the category mode for cats where the page hasn't been filled out yet.
2007-03-29 14:17:10 +00:00
Domas Mituzas
ff7bc88a49 define querygroup 2007-03-25 16:12:07 +00:00
Greg Sabino Mullane
3e5761b57f More GROUP BY fun, fixes bug #9363, thanks to Mathias Behrie 2007-03-21 22:53:06 +00:00
Aaron Schulz
615935c4a6 *Add rc_deleted 2007-03-14 01:55:44 +00:00
Raimond Spekking
b82977221a fix for r20148. Thanks to Nikerabbit for save me from stabbing 2007-03-05 21:49:26 +00:00
Raimond Spekking
fbe7f1a859 Same behavior for 'rcnote' as on RC and WL
Extra error message if list is empty
2007-03-05 18:44:42 +00:00
Nick Jenkins
f88c771756 The war on redundant ampersand usage!
* Convert "$dbw =& wfGetDB( DB_MASTER );" --> "$dbw = wfGetDB( DB_MASTER );"
* convert "$skin =& $wgUser->getSkin();" --> "$skin = $wgUser->getSkin();"

For the time being have not changed the function definitions of wfGetDB() or User::getSkin() [i.e. they are still both return-by-ref], so as to ensure the interface does not change for extensions [some of which may still be trying to run on PHP4 environments]. However presumably at some point this can be changed too.

Also includes tiny tweak to newlines in parserTests - will show 1 rather than 2 newlines between the "Reading tests from" strings when in quiet mode.
2007-01-22 23:50:42 +00:00
Antoine Musso
c771fc9c96 Use Doxygen @addtogroup instead of phpdoc @package && @subpackage 2007-01-20 15:09:52 +00:00
Greg Sabino Mullane
13566d2a9f Add 2 new select-clause columns to groupby clause. 2007-01-12 19:30:12 +00:00
Antoine Musso
171945efed User::getOption now accept a default value to override default user values
this makes it consistent with WebRequest::get* methods. Corrected code in
various places accordingly.
2006-12-14 20:28:38 +00:00
Leon Weber
6362c4f645 Fixing a bug in my last commit to make it also work on related changes. 2006-12-09 12:28:02 +00:00
Nick Jenkins
a474761d9a Changing lines like this: "extract( $dbw->tableNames( 'page', 'archive' ) );" to be like this: "list ($page, $archive) = $dbw->tableNamesN( 'page', 'archive' );".
Three reasons for this:
1) It's better for analysis tools [which want explicit variable declaration]
2) It's easier for a human to read, as it's completely explicit where the variables came from [which is something you don't get with extract() ]
3) It makes it easier to find everywhere where a variable is used with search/grep [which you can't currently do with $tbl_page variables from things like: "extract($db->tableNames( 'page', 'revision'), EXTR_PREFIX_ALL, 'tbl');"].

Otherwise, from a functionality/efficiency perspective the two forms should be identical.

By doing this have been able run static analysis over the usages of these variables, thus eliminating 5 unneeded table names from calls, plus removing 3 unused calls entirely, and it just feels subjectively slightly nicer to me.
2006-11-27 08:36:57 +00:00
Nick Jenkins
14c53b728f Code housekeeping stuff (and barring any stuff-ups on my behalf, there should be no changes in behaviour whatsoever after this) -
* removing some unused global declarations.
* removing or commenting out or adding comments for unused local vars.
* Adding one or two local var declarations.
* Declaring $matches array passed to preg_match() / preg_match_all() as array() before using [not required, just have a slight preference for the explicitness].
* remove one or two pass-by-reference function declarations where the value is not modified.
* Adding some braces to if-else blocks.
* In Parser.php, stripstrate is now an object rather than an array as per r17820, so we no longer need ask for a reference to it (as in "$x =& $this->mStripState;"), and in fact it's probably just simpler to get rid of $x altogether.
* Moving some preg regexes from "" quoting to '' quoting to stop static analyzer whinging about bad escape sequences.

... up to "LinksUpdate.php" in the includes/ directory.
2006-11-23 08:25:56 +00:00
Tim Starling
36ed0cd96c Reverting 17479/17480, breaks subclassing of Linker methods by skins. See my comment on bug 7405. 2006-11-08 07:12:03 +00:00
Nick Jenkins
fa239349f2 * (bug 7405) Make Linker methods static. Patch by Dan Li. 2006-11-08 05:21:15 +00:00
Greg Sabino Mullane
e15edf0886 Refactor GROUP BY clause, add extra columns for SQL compatibility, remove debugging code.
Tested on MySQL with both $uid and !$uid. :)
2006-08-04 20:18:43 +00:00
Brion Vibber
2a7e63c972 revert 15898, broke the wiki 2006-08-03 03:09:05 +00:00
Greg Sabino Mullane
d25e25c9c8 Make SQL more SQL compliant, remove some debugging code. 2006-07-30 23:32:50 +00:00
Niklas Laxström
e764efd53a * ChangesList assumes rc_bot exists 2006-06-29 19:56:32 +00:00
Rob Church
4211102821 (bug 5817) Appropriate handling for Special:Recentchangeslinked where the target page doesn't exist 2006-05-03 18:54:28 +00:00
Rob Church
eb935e81c8 (bug 5696) Add a third parameter, $3, to "rcnote", passing the current time formatted according to the current user's settings 2006-05-01 00:12:07 +00:00
Lupin
11337038b3 removing unused globals and some whitespace cleaning 2006-03-07 01:10:39 +00:00
Magnus Manske
b1c16bd4d6 Fixing bug 2082: Related changes views (Special:Recentchangeslinked) do not indicate one's watched page 2006-01-08 15:59:16 +00:00
Ævar Arnfjörð Bjarmason
a26d5a49d7 * s~\t+$~~ 2006-01-07 13:31:29 +00:00
Ævar Arnfjörð Bjarmason
7bbe971aec * s~ +$~~ 2006-01-07 13:09:30 +00:00
Antoine Musso
2ca68a256d Clean up unused globals! 2005-12-04 18:27:59 +00:00
Brion Vibber
72ad47d183 * (bug 4090) Fix diff links in Special:Recentchangeslinked 2005-11-27 09:53:13 +00:00
Brion Vibber
ece0b3e88f * (bug 4059) fix 'hide minor edits' on Recentchangeslinked
Needed to change rev_minor_edit in where clause to rc_minor, can't
use the aliased column name there.
2005-11-23 20:14:36 +00:00
Domas Mituzas
d0b4d2cc9a categories deserve recentchanges based recentchanges linked queries as well 2005-11-12 20:43:21 +00:00
Domas Mituzas
f0b5872333 recentchanges based recentchanges linked 2005-11-12 20:06:28 +00:00
Domas Mituzas
4bf83c2dd8 page_timestamp does not exist, eh eh, page_touched does though.. 2005-11-12 19:39:17 +00:00
Domas Mituzas
c738759377 there were two queries to be fixed, ... 2005-11-12 17:04:13 +00:00
Domas Mituzas
a360518cfb do not join revision for pages not touched, saves some cpu and i/o 2005-11-12 15:34:07 +00:00
Brion Vibber
3eac584406 * Clean up duplicate code for selection of changeslist style
in part for bug 3467
2005-09-15 00:40:51 +00:00
Antoine Musso
e00b2f8d2e Split enhanced and old changelist in two classes that inherit from the main
class. Need to setup more methods :)
2005-09-06 18:43:45 +00:00
Brion Vibber
de595c3eed More HTML validation checks on page subtitle. Not exploitable, but could create validation errors. 2005-08-25 04:31:46 +00:00
Antoine Musso
7dcb3eaf38 first letter lowercase 2005-08-16 21:02:15 +00:00
Antoine Musso
b91cc79f32 fix #923 : correct title for RCLinked special page 2005-07-03 19:20:42 +00:00
Brion Vibber
753cfc1553 * Various code cleanup and HTML escaping fixlets on page history, contribs etc
* fix page history with table prefix
* fix paging on history
* switch 'earliest' and 'latest' link order to fix 'prev' and 'next'
* use null where appropriate
* switch some messages to plaintext or wikitext
2005-06-29 06:16:03 +00:00
Brion Vibber
e0ce5a322e * links and brokenlinks tables merged to pagelinks; this will reduce pain
dealing with moves and deletes of widely-linked pages.

The updaters should be fixed up to understand future versions without the
tables there without breaking upgrades.
2005-05-26 10:23:36 +00:00
Ævar Arnfjörð Bjarmason
1ec4bb9890 * Special:Allpages, Special:Contributions, Special:Whatlinkshere
Special:Recentchangeslinked and Special:Emailuser all mishandled being passed
  "0" with the Special:Page/0 syntax (unrelated to bug 2087), this either
  required a workaround in the form of passing "0" as a GET value or blocked
  the user from passing that value at all.
2005-05-06 11:20:37 +00:00
Domas Mituzas
0aa2629efc remove inverse_timestamp wherever it is found and disable wfInvertTimestamp()
dear mysql3, try to remember how beautiful filesorts are, you're so good at it.
2005-02-21 15:33:58 +00:00
Brion Vibber
b7d89cb717 Somebody forgot the table names *ahem* 2005-02-08 20:46:22 +00:00
Brion Vibber
64ac6b8e77 Merge SCHEMA_WORK into HEAD. Lots of changes, some things are probably broken:
* Page moves/overwrites are a little iffy
* Compression might not be working right
* Profit!
2004-12-19 08:00:50 +00:00
Brion Vibber
798270581d (bug 454) Merge e-notif 2.00
From http://bugzilla.wikipedia.org/attachment.cgi?id=171&action=view
and extra files from http://www.tgries.de/mw/cvs15+enea200-minus-cvs.tgz

Undid a couple minor bits like the broken changing of minoreditletter.
Have not yet made general corrections/reworkings. Since this changes
the user and watchlist tables, you must run the updaters (installer or
update.php) on an existing database.
2004-12-18 03:47:11 +00:00
Brion Vibber
d0bc0b3f4a (bug 144) Dan Keshet's category backlinks special-casing patch, with sql escaping fix. 2004-12-03 08:12:50 +00:00
Brion Vibber
ef985d1362 Split recentchanges and image history list formatters from Skin, where they never really belonged. No skin overrides these things, and they just waste server time loading and parsing the code for every page hit where they're not needed. 2004-11-25 13:47:17 +00:00
Zheng Zhu
c05629c010 Third batch of files modified to replace selected wgLang with wgContLang 2004-09-24 16:45:31 +00:00
Antoine Musso
ba2afcd9fa Split files and classes in different packages for phpdocumentor. I probably changed some double quotes to single and used function foo () { shema 2004-09-03 23:00:01 +00:00