Subject: | Patch to fix CMS::MediaWiki module |
Date: | Sat, 23 May 2009 00:00:34 +0000 (GMT) |
To: | bug-CMS-MediaWiki [...] rt.cpan.org, retoh [...] cpan.org |
From: | Jack Grahl <jack.grahl [...] yahoo.co.uk> |
Dear Reto,
Currently the module doesnt seem to work to either login or edit; the following patch appears to be the solution.
--- MediaWiki.pm.old 2009-05-23 00:35:09.000000000 +0100
+++ MediaWiki.pm 2009-05-23 00:34:18.000000000 +0100
@@ -77,7 +77,7 @@
my $index_path = "/index.php";
$index_path = "/$args{'path'}/index.php" if $args{'path'};
- my $login_url = "$args{'protocol'}://$args{'host'}$index_path?title=Special:Userlogin&action=submitlogin&type=login";
+ my $login_url = "$args{'protocol'}://$args{'host'}$index_path?title=Special:Userlogin&action=submitlogin&type=login";
Debug "[login] POST $login_url\..." if $self->{'debug'};
@@ -177,7 +177,7 @@
$tags{'action' } = 'submit';
$resp = $ua->request(
- POST "$args{'protocol'}://$WHOST/$WPATH/index.php?title=$args{'title'}&action=submit" ,
+ POST "$args{'protocol'}://$WHOST/$WPATH/index.php?title=$args{'title'}&action=submit" ,
Content_Type => 'application/x-www-form-urlencoded' ,
Content => [ %tags ]
);
I hope this helps; if not I will supply more infomation about the specific problem.
Yours, Jack Grahl