Sam Reed
ae29df4914
Fix -rakkaus/#mediawiki-i18n- [06-Jan-2011 16:10:59] PHP Notice: Undefined variable: text in /www/w/includes/api/ApiParse.php on line 295 from r79455
2011-01-06 16:24:49 +00:00
Platonides
9a5c36d3c1
Unused global
2011-01-05 23:59:04 +00:00
Sam Reed
359964eafc
* (bug 25135) add "normalized" to action=parse
...
Mov addition of $oldid earlier
2011-01-04 21:37:18 +00:00
Ilmari Karonen
ff0a67c75e
make action=parse return a missingtitle error if the page param refers to a missing (rather than just invalid) title
2011-01-03 23:20:13 +00:00
Sam Reed
5b1a5aa763
ApiQueryRevisions: Switch from manual Cache checking, to use $article->getParserOutput()
...
ApiParse: Fix comment typo
2011-01-02 03:20:45 +00:00
Sam Reed
03ada62815
Add missing $popts parameter, and pass it from r79455
2011-01-01 23:06:04 +00:00
Sam Reed
49c8975c3b
Allow section to work with oldid when oldid == currentrevid (worked with older id)
2011-01-01 23:01:24 +00:00
Sam Reed
7d79c3ae7b
Per Platonides on CR r75334, use $article->getParserOutput() to get latest revision, rather than doing parser cache stuff ourselves
...
Helps reduce code duplication too
2011-01-01 22:49:47 +00:00
Sam Reed
d6ca7358f2
Per Nikerabbit on IRC, and Bryan on CR (r79451), change back for ===, and intval( $oldid )
2011-01-01 22:42:53 +00:00
Sam Reed
80c7f081fb
Followup r75334. Change to int == string, rather than int === string (not going to work)
...
Attempt to load/save an article object, rather than an title object from the parser cache.
Per Bryan, and per bug 26534 now logged, this really needs refactoring more cleanly. As if latestRevId == oldid set, it's doing exactly the same lookup/parse
2011-01-01 22:35:16 +00:00
Sam Reed
1f05665cf3
Styleli[zs]e the API up to date (Been a while since)
2010-12-30 17:06:09 +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
Roan Kattouw
b81ac8ea52
Improve some of the descriptions added in r68482
2010-12-14 11:47:13 +00:00
Priyanka Dhanda
f9cc3b783a
Part of fix/workaround to bug 26163. API calls to get language links and categories as html
2010-12-06 18:31:09 +00:00
Sam Reed
cc0574856f
Fixup fail from r76191. Thanks Nikerabbit
2010-11-06 16:11:19 +00:00
Sam Reed
84fed26fd4
Add missing credits from r75975
...
Remove a few unused array keys in API foreach loops
Remove part of Html::Hidden comment
2010-11-06 15:10:18 +00:00
Sam Reed
a14da45336
* If a action=parse request provides an oldid that is actually the current revision id, try the parser cache, and save it to it if necessary
2010-10-24 19:16:46 +00:00
Sam Reed
8b03a013a1
Fix some method documentation
...
Fix some typos
Some explicit class members
2010-10-20 18:50:33 +00:00
Sam Reed
48a042cbf6
Remove some unneeded whitespace
2010-08-23 22:18:05 +00:00
Alexandre Emsenhuber
457eb73b61
Standardised file description headers, added @file
2010-08-07 19:59:42 +00:00
Sam Reed
8f504f6763
* (bug 24656) API's parse module needs option to disable PP report
2010-08-04 07:44:23 +00:00
Sam Reed
5387b8a806
Stylize API up to date
...
Fix spaces from r69755
Minor update to RELEASE-NOTES per r69753
2010-07-23 07:33:40 +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
Mark A. Hershberger
e28aaea397
follow up r69339:
...
* Add a missing setVaryCookie for consistency
* don't cache result when token is given in ApiFeedWatchlist
2010-07-14 21:46:52 +00:00
Roan Kattouw
70824ccccc
API: Make output containing private or user-specific data uncacheable for logged-in users by setting Vary: Cookie or Cache-Control: private, whichever is appropriate. Fixes instances in core and WMF-deployed extensions only. Without this change, the output of requests like ?action=query&list=recentchanges&rcprop=patrolled&smaxage=3600 would be cached in Squid and viewable for anyone using the same URL, even if they don't have patrol rights. Other, more serious exploits are also possible. Also avoid using $wgUser in one place, kill some unused global $wgUser; instances and tweak a comment.
2010-07-14 19:00:54 +00:00
Sam Reed
f5c639fd10
Stylize API
...
Add a few braces
2010-07-06 13:15:59 +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
499f972752
Followup to r66873
...
If title valid, append URL to parse output
2010-05-25 18:37:55 +00:00
Sam Reed
8b3ce85253
Part of bug 23254 - Add interwiki links to parse output
2010-05-25 13:47:22 +00:00
Sam Reed
8f9e12de0e
bug 18608 done in a fashion much closer to how I should've done it originally.
...
Latching onto bug 22061 output
Following up r62195 and r61125
2010-05-24 16:35:23 +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
Sam Reed
38105564d7
Fixup getPossibleErrors description from r66150, add missing placeholders
2010-05-10 18:54:33 +00:00
Sam Reed
c9574e66cc
* (bug 23460) Parse action should have a section option
...
Also add uselang parameter, not originally added in r63428
Clarify section description in both. Move global into if statement
2010-05-10 18:27:58 +00:00
Sam Reed
e771204962
* (bug 23458) Add support for pageid parameter to action=parse requests
...
Nest code in else for oldid. Add in missing assignment to $wgTitle in that code path
Remove some whitespace. Fix minor typo/wrong word
2010-05-10 14:17:21 +00:00
Sam Reed
72a96d86ad
Nicer wording, as per werdna on irc
2010-05-10 13:30:22 +00:00
Sam Reed
0769301e87
Stylize Api upto date
2010-04-17 20:58:04 +00:00
Sam Reed
dc4786f86c
Minor followup to r63425 and r63428
...
Set $oldLang to null, and only reset if !is_null( $oldLang )
Also, only change language on ApiQueryAllmessages if wanted language != current language
2010-03-09 11:52:43 +00:00
Sam Reed
56d0e5d943
Minor comment for r63428
2010-03-08 22:36:52 +00:00
Sam Reed
3665c17bcf
* (bug 22764) uselang parameter for action=parse
...
Also add a few full stops to normalise format of Params
2010-03-08 22:32:17 +00:00
Jack Phoenix
c286869e38
API: fix copyright symbol, coding style cleanup, more braces
2010-02-23 18:05:46 +00:00
Sam Reed
4365dc9c75
Fixup result_array
2010-02-19 18:28:52 +00:00
Sam Reed
80f9448690
Start of "Bug 21991 - Move common query parameter (uc, rc) validation, token requiringness/checking to ApiBase/Similar"
...
Move token requringness check to the ApiMain
Adding an exception if we're using "gettoken" (block/unblock)
Remove array( 'missingparam', 'token' ), from the getPossibleErrors of modules that set requireToken method to true
2010-02-14 22:20:27 +00:00
Sam Reed
6911358977
Complete dieUsage errors in 6 more Api files
2010-02-13 01:05:14 +00:00
Roan Kattouw
82c185b6e1
Whitespace fixes for r62195, remove out-of-context comment
2010-02-10 10:54:00 +00:00
Sam Reed
6669386809
* (bug 18608) - API should provide list of CSS styles to apply to rendered output
2010-02-09 20:47:35 +00:00
Sam Reed
f73c8436e4
Part 1 of bug 18427 - "add comment= parameter to action=parse, spitting out <parsedcomment> with
...
the HTML"
Done outputting "parsedsummary", though, summary may suffice?
2010-01-31 17:45:51 +00:00
Sam Reed
b15f2c8c46
Normalise comment usage (# --> //)
2010-01-23 22:52:40 +00:00
Sam Reed
b739e97341
More of r61437 (adding/removing whitespace)
2010-01-23 22:47:49 +00:00