Re: [Mediawiki-api] Bad or Invalid Token in Extension

2014-04-28 Thread Brad Jorsch (Anomie)
On Sun, Apr 27, 2014 at 1:20 PM, Liangent liang...@gmail.com wrote: Well you can just use Title::moveTo() directly. Yes, this. It's rarely necessary and often a mistake to use FauxRequest to call the local wiki's API. And using curl to hit the local wiki is likely even worse. On Sun, Apr 27,

Re: [Mediawiki-api] Bad or Invalid Token in Extension

2014-04-28 Thread Justin Maldonado
...@lists.wikimedia.org] On Behalf Of Brad Jorsch (Anomie) Sent: Monday, April 28, 2014 8:48 AM To: MediaWiki API announcements discussion Subject: Re: [Mediawiki-api] Bad or Invalid Token in Extension On Sun, Apr 27, 2014 at 1:20 PM, Liangent liang...@gmail.com wrote: Well you can just use Title::moveTo

[Mediawiki-api] Bad or Invalid Token in Extension

2014-04-27 Thread Justin Maldonado
I'm trying to make a simple extension that moves a page on my mediawiki site, but whether using curl or FauxRequest, I always get bad token response. Tried urlencoding, not encoding, %2B/, without +/, etc, doesn't matter. The token shown in the output looks identical to the one when

Re: [Mediawiki-api] Bad or Invalid Token in Extension

2014-04-27 Thread Betacommand
you should be using the move token not the edit token On Sun, Apr 27, 2014 at 12:28 PM, Justin Maldonado i...@keyappraising.comwrote: I'm trying to make a simple extension that moves a page on my mediawiki site, but whether using curl or FauxRequest, I always get bad token response. Tried

Re: [Mediawiki-api] Bad or Invalid Token in Extension

2014-04-27 Thread Justin Maldonado
11:56 AM To: MediaWiki API announcements discussion Subject: Re: [Mediawiki-api] Bad or Invalid Token in Extension I don't have enough time right now to have a deeper look at your code, but: $token = $token = $wgUser-editToken(); Although this isn't an error, it's still unnecessary. Next

Re: [Mediawiki-api] Bad or Invalid Token in Extension

2014-04-27 Thread Liangent
...@lists.wikimedia.org [mailto: mediawiki-api-boun...@lists.wikimedia.org] *On Behalf Of *Niklas Keller *Sent:* Sunday, April 27, 2014 11:56 AM *To:* MediaWiki API announcements discussion *Subject:* Re: [Mediawiki-api] Bad or Invalid Token in Extension I don't have enough time right now to have