Commit graph

145 commits

Author SHA1 Message Date
Alexandre Emsenhuber
1e8992ca74 Follow-up I0b781c11 (2a55449): use User::getAutomaticGroups().
No need to duplicate the code of User::getAutomaticGroups() in
ApiQueryUsers::getAutoGroups(), instead just call that method
directly.
Also deprecated the latter in favour of the former and replaced
all calls in core.

Change-Id: I224cb610cbd6a927a4c7f7137951416368f8cb5d
2012-08-03 21:41:44 +02:00
Antoine Musso
4f5d2386f3 escape HTML elements in docblock with double quotes
Doxygen choke on text enclosed by '<' and '>' since it tries to
interpret them as HTML or XML elements. This patch adds double quotes
in includes/api/*.php files around the two following strings:

 <Firstname>.<Lastname>@gmail.com
 <Firstname><Lastname>@gmail.com

Which becomes:

 "<Firstname>.<Lastname>@gmail.com"
 "<Firstname><Lastname>@gmail.com"

Tested locally, it prevents doxygen 1.8.0 related warnings.

Change-Id: I36d82eb3fd4989ee3ffc65b0b527b83711d1ba69
2012-07-15 22:15:45 +02:00
Petr Onderka
80aa025528 Added result properties to action=paraminfo
Added information about the properties of the results of API calls
to action=paraminfo, including information about "property groups":
what should the prop parameter be set to to get that property.

Uses the same format for types as parameters already do.
The output format of some modules doesn't fit this, so the result
properties for them weren't added, or only partially.

Partially implemented modules:
* expandtemplates:
  parsetree is in its own tag
* protect, allusers, backlinks, deletedrevs, info, imageinfo,
  logevents, querypage, recentchanges, revisions, searchinfo,
  usercontribs, userinfo, users, watchlist, upload:
  response with partially complex structure

Not implemented modules:
* feedcontributions, feedwatchlist, opensearch, rds:
  non-standard reponse
* help:
  error is normal response; not very useful for automated tools anyway
* paraminfo, parse, pageprops, siteinfo, userrights:
  response with complex structure

Change-Id: Iff2a9bef79f994e73eef3062b4dd5461bff968ab
2012-06-06 19:24:59 +02:00
awjrichards
c29fd59775 Big oops - merged to wrong branch.
Revert "Revert to arbitrarily old point before initial remote branch creation to help clean up"

This reverts commit ee0d3d330f
2012-06-05 22:58:54 +00:00
awjrichards
ee0d3d330f Revert to arbitrarily old point before initial remote branch creation to help clean up
Change-Id: I41a3d1e55d3ea9dffa42451237fe065f9334361d
2012-06-02 08:43:04 -07:00
Hoo man
932774a5e2 Fixed the API doc. for aurights (list=allusers)
Listings with aurights can't show users with rights which are
granted by implicit or auto-promoted groups like *, user, or autoconfirmed.
This is my first commit, btw.

Change-Id: I083eb977393729961317d0f3cf9f7cfaa50fde51
2012-05-29 14:17:19 +02:00
Aaron Schulz
fdb74872a8 Merge "multi dbms support in api" 2012-05-20 18:15:42 +00:00
umherirrender
278bb4414f multi dbms support in api
Add some calls to Database::timestamp
Change some calls from Database::strencode to
Database::addQuotes to avoid ' in raw sql
Remove ' from ints in raw sql
Rename some vars to avoid duplicate names

Change-Id: I63f5602fa968f969a42932902a3ccc45fc54b432
2012-05-16 19:22:36 +02:00
Reedy
c87a63935a Merge "(bug 19195) Make user IDs more readily available with the API" 2012-05-10 18:47:42 +00:00
Szymon Świerkosz
b433d1958b (bug 33602) list=allusers throws exceptions with invalid names
Follow up to: I7d115e734cb8c93dcf6dc3b98bdbc81975951273.
I have replaced $this->keyToTitle calls with simple str_replace.
As a result invalid user names will be accepted in parameters, so
the chain of requests based on query-continue will not be broken
by invalid entry in the database.

Change-Id: I8a80fe6395ae6e9304e4d9ec7b604195ec3c9d00
2012-04-26 23:45:09 +02:00
umherirrender
426ccbf42e (bug 19195) Make user IDs more readily available with the API
Add some block ids and user ids to the result of some modules

Change-Id: If50604b888a54827eddde76574e779db6c7263ec
2012-04-22 14:20:46 +02:00
Szymon Świerkosz
6cf8cd357e (bug 33602) list=allusers throws exceptions with invalid names
Some MediaWiki installations have invalid user names in user table
(most notable example: en.wikipedia). This commit DOES NOT resolve
the issue completely, it only makes the API behave more gracefully.

I have replaced User::newFromName call with User::newFromId, so the
User object should be always constructed. In case it was not, an
empty array will be provided instead of null when returning user
rights. I have removed keyToTitle calls for ContinueEnumParameter
as user names in the database are stored without underscores
(en.wikipedia has of course one user with _ in the database...).
This should fix invalidtitle error thrown.

There is one issue I don't know how to solve. When API outputs in
query-continue aufrom value with invalid user name, subsequent
call with aufrom set will return an error, because input parameters
'from' and 'to' are passed to keyToTitle method too. Should I
replace it with simple str_replace('_', ' ')?

Change-Id: I7d115e734cb8c93dcf6dc3b98bdbc81975951273
2012-04-15 10:37:03 +02:00
Sam Reed
107489687a Merge r111667 into trunk 2012-02-16 20:13:35 +00:00
Sam Reed
53000baecf Oh noes, moar http:// -> https:// 2011-11-28 15:43:11 +00:00
John Du Hart
2e7d867478 Removed the 'eclipse helper' bit on top of every API module
It's a parctice that dates back to 2006 when the API was first written, and frankly isn't covered by the coding conventions. Same thing with the docblocks, they're all copypasted with some bits changed and don't even make sense if you look at them in the genereated code docs.
I don't feel that any of us depend on this anymore (get a better IDE), so in the inerest of consistancy it's time we said goodbye to it.
2011-11-16 00:17:26 +00:00
Roan Kattouw
cd9b698d8e list=allusers was throwing fatals when invalid user names occurred in the database. Address this scenario gracefully 2011-10-11 15:45:27 +00:00
Sam Reed
bd6ecdca92 Fix whitespace 2011-09-28 16:37:27 +00:00
Sam Reed
5ed71b715e Bug 31199 - Fix notification of implicit groups so it doesn't massively change json output
Needs merging to 1.18, 1.18wmf1 and pushing to site
2011-09-28 16:36:17 +00:00
Sam Reed
a5628f5734 Based on diff to wikia, set more functions consistently public rather than protected 2011-08-17 22:24:21 +00:00
Sam Reed
d510cdd91d * (bug 29938) list=users&usprop=rights shows rights the user doesn't have 2011-07-18 21:26:33 +00:00
Sam Reed
c62b074da7 Remove call to User::getImplicitGroups() from ApiQueryAllUsers
Per the below, as User::getGroupsWithPermission() will return */autoconfirmed, etc if applicable

> var_dump( User::getGroupsWithPermission( 'createtalk' ) );
array(2) {
  [0]=>
  string(1) "*"
  [1]=>
  string(4) "user"
}

> var_dump( User::getGroupsWithPermission( 'autoconfirmed' ) );
array(5) {
  [0]=>
  string(13) "autoconfirmed"
  [1]=>
  string(3) "bot"
  [2]=>
  string(5) "sysop"
  [3]=>
  string(8) "reviewer"
  [4]=>
  string(9) "confirmed"
}
2011-07-18 16:09:50 +00:00
Sam Reed
9c37ab4fb3 * (bug 28817) Add reference help page link to API Modules
Last followup of r92396

Should be all modules with documentation pages in core now documented...
2011-07-17 17:02:06 +00:00
Brion Vibber
c2f924a509 * (bug 28634) document possible API caveat caused by accounts without the registration time field 2011-05-13 15:04:55 +00:00
Sam Reed
0b96c67a9e Remove unneeded manual quoting from r87180 2011-05-01 11:20:14 +00:00
Sam Reed
5283490bdd * (bug 28225) Allow hiding of user groups in list=allusers
Yay, a LEFT OUTER JOIN
2011-05-01 00:24:39 +00:00
Sam Reed
ab28af877c Followup r85884
Fixup the APIs strange way of doing table aliases on a join....

Only used in very few places
2011-04-30 23:18:34 +00:00
Sam Reed
76a4e7d4ce Followup r84363
Looks like I made a complete hash of that commit. Commit correct version from vm working copy
2011-03-26 18:39:22 +00:00
Sam Reed
74cfe3df00 Followup r79549, only try and filter by group (or right) if there are some groups to do a WHERE on 2011-03-24 20:27:30 +00:00
Sam Reed
e696d174eb Actually list implicit groups in allusers.
Looks like I might've regressed this in the course of fixing other bugs. Oh well, fixed now
2011-03-20 00:23:41 +00:00
Sam Reed
82dd198876 Followup r83849, fix join to be on indexed user_name 2011-03-14 11:07:58 +00:00
Sam Reed
886a70a3f7 Add missing group by from r83849 per Bryan 2011-03-13 19:35:08 +00:00
Sam Reed
237eb87db4 * (bug 26630) Add api for Special:ActiveUsers
Not sure if this would be better having been done as list=activeusers or something...

Meh, done! :P
2011-03-13 19:07:22 +00:00
Sam Reed
cb94b8f191 * (bug 27342) Add audir param to list=allusers 2011-03-13 17:23:45 +00:00
Sam Reed
aea7a5a482 Followup r83390
If the user is allowed to view hidden users, put a missing property on all users.

For list=users, do the same, but we can't easily distinguish to other people the difference between "hidden", or "missing", so no reason to do it
2011-03-06 20:51:31 +00:00
Sam Reed
67d4ee1d26 Followup r83390, change cache modes 2011-03-06 18:16:44 +00:00
Sam Reed
c488abeeb8 * (bug 27897) list=allusers and list=users list hidden users
Refactored addition of block information, and also checked if user is allowed to view hidden user fields
2011-03-06 17:59:08 +00:00
Sam Reed
20d56c63b3 * (bug 27708) list=users does not have a property to return user id
Add userid to ApiQueryUsers

Move userid in ApiQueryAllUsers before name
2011-02-25 16:19:44 +00:00
Sam Reed
35296f391f Followup to r82739 (bug 27688)
Remove u1 table aliases
2011-02-24 18:46:12 +00:00
Sam Reed
57923b31fa * (bug 27688) Simplify queries to list user block information
Also expose block expiry information, listed on Users, but not all users

Some minor simplifications to come
2011-02-24 18:43:44 +00:00
Sam Reed
521044a529 Explicitally define $fld_rights on all code paths 2011-02-09 22:42:26 +00:00
Sam Reed
22832a2527 * (bug 26560) On allusers if limit < total number of users, last user gets duplicate
If $lastUserData is set to null, it won't get added again!
2011-01-04 04:05:32 +00:00
Sam Reed
df0a765cfe * (bug 26559) list=allusers auprop=rights does not match list=users usprop=rights 2011-01-04 03:36:39 +00:00
Sam Reed
0014c1113c * (bug 26558) list=allusers auprop=groups does not list groups a user is automatically a member of 2011-01-04 02:48:02 +00:00
Sam Reed
f1b7c91cf8 Followup r79545, we don't really care for duplicate userrights 2011-01-04 02:18:03 +00:00
Sam Reed
97a0295e34 Add rights to array. Grrr 2011-01-04 02:13:51 +00:00
Sam Reed
b30c1e7e72 Crappy spaces from r79549 2011-01-04 02:08:38 +00:00
Sam Reed
58df1dc895 Rest of * (bug 25767) Add userrights properties to allusers and users query lists
Add missing parameter from r79545
2011-01-04 02:06:55 +00:00
Sam Reed
e1bcab1ab8 * (bug 25767) Add userrights properties to allusers and users query lists
First part of this bug. Listing of all rights that users have
2011-01-04 01:39:02 +00:00
Sam Reed
1da2cd2dde Move comment about groups potentially returning less results from server.
Comment out description line about rights from ApiQueryUsers, as that prop doesn't exist (Might do in future. Possible artifact from large scale comment addition?)
2011-01-03 20:41:22 +00:00
Sam Reed
6309c920dd Delete all the "API for MediaWiki 1.8+" comments
Add since to ApiQueryQueryPage
2010-12-22 20:52:06 +00:00
Sam Reed
fd976ad072 Part of Bug 19195 - Make user IDs more readily available with the API
ApiQueryAllUsers, ApiQueryImageInfo and ApiQueryRevisions exposing user_id
2010-08-28 00:37:48 +00:00
Sam Reed
ec744522af I really do hate whitespace 2010-08-26 22:12:01 +00:00
Sam Reed
ca6dc55a0d * (bug 24724) list=allusers is out by 1 (shows total users - 1) 2010-08-26 22:09:29 +00:00
Sam Reed
4ef46d0006 Followup to r68338, remove useless code (row is overwritten by loop) 2010-08-18 20:34:42 +00:00
Sam Reed
1e0f0c4574 Prefix searches for users, not pages 2010-08-10 10:05:31 +00:00
X!
0f6085a585 (bug 24722) Only show blockinfo if user is actually blocked for list=allusers 2010-08-08 15:33:43 +00:00
Alexandre Emsenhuber
457eb73b61 Standardised file description headers, added @file 2010-08-07 19:59:42 +00:00
X!
7147b264bc * (bug 24677) axto= parameters added to allcategories, allimages, alllinks, allmessages, allpages, and allusers 2010-08-06 18:58:10 +00:00
Tim Starling
b2dc451c82 Rewrote r69339 etc. to clean up API cache header handling.
* Introduced a "cache mode" concept to simplify the header generation code, and to avoid odd results when conflicting cache header requests are received from submodules, or at least to formalise the handling of such cases.
* Made the cache mode private by default, so that code written in ignorance of caching tends to be safe. If different query modules are used in a single request, private caching is preferred over public caching.
* Removed the "must-revalidate" option from all CC headers, this is really specific to page views with a hacked squid in front, I don't think it's applicable here.
* Made the watchlist module private. This is really the definition of private data. There's nothing in the HTTP spec that says the URL for a CC:public request is private and can't be leaked. CC:private provides protection against unknown proxy behaviour.
* In ApiQueryAllmessages: avoid calling $wgLang->getCode() to check if it's necessary to make a new $wgLang when lang= is specified, since this is the only thing that unstubs $wgUser.
* Removed "FIXME: should this check $user instead of $wgUser?" Answer is no.
2010-07-23 07:17:56 +00:00
Sam Reed
8f1d2cb199 Big blitz on unused variables (a lot of $db = $this->getDb() ) 2010-07-22 22:13:21 +00:00
Sam Reed
2d8f0de854 Rem superfluous code, as per comments on r68338 2010-06-29 20:22:52 +00:00
Sam Reed
2d21295243 * (bug 23473) - Give description of properties on all modules
Commit patch by John Du Hart with a few minor tweaks/fixes
2010-06-23 19:36:26 +00:00
Derk-Jan Hartman
921619b119 Correct the address of the FSF in some of the GPL headers
59 Temple Place -> 51 Franklin Street
2010-06-21 13:13:32 +00:00
Sam Reed
53c5e4b942 Do ApiQueryAllUsers per r68337 (was using while (true)..) 2010-06-20 18:52:46 +00:00
Sam Reed
a90a0783de Nuke $db->freeResult() from Api stuffs 2010-06-20 17:48:21 +00:00
Roan Kattouw
37cf6f133b API: (bug 23534) Fix regression from r46809 (!) causing DB query error 2010-05-15 18:00:55 +00:00
Sam Reed
e55ed729c4 Mixture of things.
Couple of class comments

Normalisation of "." usage at end of lines (removed)

Normalisation of {prefix}parameter as per bug 23461
2010-05-11 22:30:18 +00:00
Jack Phoenix
96b4f302af API: fix copyright symbol, coding style cleanup, more braces 2010-02-24 13:34:11 +00:00
Greg Sabino Mullane
7766537c2c Use 'AS' for column alias 2010-01-26 20:36:22 +00:00
Aryeh Gregor
3758769f0d stylize.php on API code
"I wouldn't object to stylizing the API code to bring it in line with
the rest of MW on principle, but I'm not gonna bother myself." --Roan
<http://www.mediawiki.org/wiki/Special:Code/MediaWiki/60657#c5108>

If you're seeing this commit in blames, tell your blame tool to ignore
whitespace, e.g., git blame -w or svn blame -x -w.
2010-01-11 15:55:52 +00:00
Roan Kattouw
0dc85a3658 Followup to r60587: wrong user_groups join 2010-01-03 20:16:25 +00:00
Roan Kattouw
e91308e012 API: Per Domas, don't FORCE INDEX when doing an INNER JOIN with the user_groups table 2010-01-03 20:12:59 +00:00
Roan Kattouw
1acd0e17b6 API: Fix breakage due to MySQL 5.1 behavior change: replace an implicit comma join with an explicit INNER JOIN and add a FORCE INDEX 2009-12-29 11:18:50 +00:00
Roan Kattouw
4bed047624 API: Fix for r58551: WDDX formatter barfs on null 2009-12-02 12:17:27 +00:00
Alexandre Emsenhuber
3978f827a6 * (bug 21083) API: list=allusers no longer returns current timestamp for users without registration date 2009-11-04 17:18:05 +00:00
Max Semenik
ae57ab1eec (bug 20275) Fixed LIKE queries on SQLite backend
* All manually built LIKE queries in the core are replaced with a wrapper function Database::buildLike()
* This function automatically performs all escaping, so Database::escapeLike() is now almost never used
2009-10-21 19:53:03 +00:00
Roan Kattouw
2df33ff098 * API: BREAKING CHANGE: (bug 11430) Return fewer results than the limit in some cases to prevent running out of memory
* This means queries could possibly return fewer results than the limit and still set a query-continue
* Add iicontinue, rvcontinue, cicontinue, incontinue, amfrom to faciliate query-continue for these modules
* Implemented by blocking additions to the ApiResult object if they would make it too large
** Important things like query-continue values and warnings are exempt from this check
** RSS feeds and exported XML are also exempted (size-checking them would be too messy)
** Result size is checked against $wgAPIMaxResultSize, which defaults to 8 MB

For those who really care, per-file details follow:

ApiResult.php:
* Introduced ApiResult::$mSize which keeps track of the result size.
* Introduced ApiResult::size() which calculates an array's size
  (which is the sum of the strlen()s of its elements).
* ApiResult::addValue() now checks that the result size stays below
  $wgAPIMaxResultSize. If the item won't fit, it won't be added and addValue()
  will return false. Callers should check the return value and set a
  query-continue if it's false.
* Closed the back door that is ApiResult::getData(): callers can't manipulate
  the data array directly anymore so they can't bypass the result size limit.
* Added ApiResult::setIndexedTagName_internal() which will call
  setIndexedTagName() on an array already in the result. This is needed for the
  'new' order of adding results, which means addValue()ing one result at a time
  until you hit the limit or run out, then calling this function to set the tag
  name.
* Added ApiResult::disableSizeCheck() and enableSizeCheck() which disable and
  enable size checking in addValue(). This is used for stuff like query-continue
  elements and warnings which shouldn't count towards the result size.
* Added ApiResult::unsetValue() which removes an element from the result and
  decreases $mSize.

ApiBase.php:
* Like ApiResult::getData(), ApiBase::getResultData() no longer returns a
  reference.
* Use ApiResult::disableSizeCheck() in ApiBase::setWarning()

ApiQueryBase.php:
* Added ApiQueryBase::addPageSubItem(), which adds page subitems one item
  at a time.
* addPageSubItem() and addPageSubItems() now return whether the subitem
  fit in the result.
* Use ApiResult::disableSizeCheck() in setContinueEnumParameter()

ApiMain.php:
* Use ApiResult::disableSizeCheck() in ApiMain::substituteResultWithError()
* Use getParameter() rather than $mRequest to obtain requestid

DefaultSettings.php:
* Added $wgAPIMaxResultSize, with a default value of 8 MB

ApiQuery*.php:
* Added results one at a time, and set a query-continue if the result is full.

ApiQueryLangLinks.php and friends:
* Migrated from addPageSubItems() to addPageSubItem(). This eliminates the
  need for $lastId.

ApiQueryAllLinks.php, ApiQueryWatchlist.php, ApiQueryAllimages.php, ApiQuerySearch.php:
* Renamed $data to something more appropriate ($pageids, $ids or $titles)

ApiQuerySiteinfo.php:
* Abuse siprop as a query-continue parameter and set it to all props that
  couldn't be processed.

ApiQueryRandom.php:
* Doesn't do continuations, because the result is supposed to be random.
* Be smart enough to not run the second query if the results of the first
  didn't fit.

ApiQueryImageInfo.php, ApiQueryRevisions.php, ApiQueryCategoryInfo.php, ApiQueryInfo.php:
* Added continue parameter which basically skips the first so many items

ApiQueryBacklinks.php:
* Throw the result in a big array first and addValue() that one element at a time if necessary
** This is necessary because the results aren't retrieved in order
* Introduced $this->pageMap to map namespace and title to page ID
* Rewritten extractRowInfo() and extractRedirRowInfo() a little
* Declared all private member variables explicitly

ApiQueryDeletedrevs.php:
* Use a pagemap just like in Backlinks
* Introduce fake page IDs and keep track of them so we know where to add what
** This doesn't change the output format, because the fake page IDs start at 0 and are consecutive

ApiQueryAllmessages.php:
* Add amfrom to facilitate query-continue

ApiQueryUsers.php:
* Rewrite: put the getOtherUsersInfo() code in execute()
2009-02-05 14:30:59 +00:00
Roan Kattouw
b677d0191d * API: (bug 17355) Added auwitheditsonly parameter to list=allusers
* Use consistent code style
2009-02-04 19:10:14 +00:00
Roan Kattouw
8e9a43114a API: (bug 16594) Use strict comparison in list=allusers. This'll hopefully make [[User:]] on enwiki show up again; he's currently being dropped from the user list because false == '' 2008-12-11 21:51:01 +00:00
Roan Kattouw
826bcef0fa Fix regression from r36678: we can't use $this->dieUsageMsg() in a static method, so let's make ApiQueryBase::keyToTitle() and titleToKey() non-static. 2008-06-29 22:26:23 +00:00
Alexandre Emsenhuber
087a9f70c5 WARNING: HUGE COMMIT
Doxygen documentation update:
* Changed alls @addtogroup to @ingroup. @addtogroup adds the comment to the group description, but doesn't add the file, class, function, ... to the group like @ingroup does. See for example http://svn.wikimedia.org/doc/group__SpecialPage.html where it's impossible to see related files, classes, ... that should belong to that group.
* Added @file to file description, it seems that it should be explicitely decalred for file descriptions, otherwise doxygen will think that the comment document the first class, variabled, function, ... that is in that file.
* Removed some empty comments
* Removed some ?>

Added following groups:
* ExternalStorage
* JobQueue
* MaintenanceLanguage

One more thing: there are still a lot of warnings when generating the doc.
2008-05-20 17:13:28 +00:00
Roan Kattouw
5b8213e9ef * Re-applying r34449, r34500 and r34518 which Brion reverted by accident
* Adding ApiQueryBase::addJoinConds() as wrapper for Database::select()'s $join_conds parameter
* Migrating query modules to addJoinConds()
* Using implicit join rather than INNER JOIN in ApiQueryBacklinks
* Using FORCE INDEX (times) on logging table in ApiQueryLogEvents; although MySQL 4 seems to pick this index automatically (evidenced by the fact the WMF servers are still alive), MySQL 5 doesn't and filesorts
* Replacing LEFT JOIN with implicit (inner) join in ApiQueryContributions: revisions without a corresponding page table entry shouldn't be shown anyway
2008-05-10 10:49:26 +00:00
Brion Vibber
4bc02c88ca Revert to r34430 in order to revert r34431 which is breaking the site (unindexed filesorts) 2008-05-09 18:00:15 +00:00
Roan Kattouw
10274469e5 (bug 14022) Added usprop=registration and auprop=blockinfo 2008-05-09 10:00:34 +00:00
Roan Kattouw
b7d460aaeb API:
* Added ApiQueryBase::addJoin() which provides a cleaner interface to construct JOIN queries. Behind the scenes this still uses the old, ugly way, but it'll be easy to rewrite when/if the Database class gets its own function for JOINs
* Used addJoin() in query modules where necessary
* Removed FORCE INDEX (rc_timestamp) from ApiQueryRecentchanges: it's nigh impossible to integrate with addJoin() and it doesn't seem to be necessary anyway (my MySQL instance automatically chooses rc_timestamp)
2008-05-08 12:33:20 +00:00
Roan Kattouw
fa2ac03100 Reverting r34388, DanTMan fixed Database::select() in r34442. 2008-05-08 10:05:32 +00:00
Roan Kattouw
73158bd6de Fixing regression from r34353: using Database::select() for a join messes up in certain cases (puts `s where they don't belong, breaking SQL), but not for all joins. Seems to be related to table aliases, not sure though. 2008-05-07 18:57:06 +00:00
Siebrand Mazeland
79d5225c0e * remove end of line whitespace
* remove empty lines at end of file
* remove "?>" where still present
2008-04-14 07:45:50 +00:00
Roan Kattouw
19358606a1 API: Changing all modules' getParamDescription(), getAllowedParams() and getDescription() methods to public. ApiParamInfo needs them, and some versions of PHP threw fatal errors because they were protected. Oddly, other versions didn't (maybe because the caller and the callee have a common ancestor?) 2008-01-28 19:05:26 +00:00
Victor Vasiliev
0495f90ebb Revert r28215: incorrectly moved files 2007-12-06 18:33:18 +00:00
Victor Vasiliev
4e4cdf079e Create includes/api/query for Query API and includes/api/edit for Edit API 2007-12-06 18:22:15 +00:00
Daniel Cannon
3a5199af84 (bug 11562) API: Added a user_registration parameter/field to the list=allusers query. Patch by Bryan Tong Minh <Bryan.TongMinh at gmail.com>. 2007-10-26 03:48:58 +00:00
Rob Church
972a93bd6d * (bug 10971) aufrom parameter doesn't work with spaces
* Fix username handling issue with `auprefix` parameter

Usernames are *not* stored in "key" format, and treating them as such will cause various comparisons to misbehave. This was preventing `aufrom` from including the username (as it was supposed to) and would have broken `auprefix` for all comparisons containing spaces.

As a side-effect, both these parameters will now treat underscores as equivalent to spaces.
2007-08-17 13:01:35 +00:00
Yuri Astrakhan
ce91d949f7 API:
* Added full text search in titles and content (list=search)
* (bug 10684) Expanded list=allusers functionality
* Possible breaking change: prop=revisions no longer includes pageid for rvprop=ids
* Bug fix: proper search escaping for SQL LIKE queries.
2007-07-30 08:09:15 +00:00
Yuri Astrakhan
70970c90b2 API: Added list=allusers to allow enumeration of the registered users 2007-07-08 07:50:56 +00:00