Subject: | Update needed: Content-type instead of Content-Type |
Also Mediawiki-Client worked very well up to version 1.5.0 of MediaWiki, now, with latest version 1.5.2 mvs login doesn't fully work in the sense that the .mediawiki encoding is unset instead of being set to utf-8 for example. In fact this bug might come from the server which is supposed to send a meta which looks like meta http-equiv="Content-Type" content="text/html; charset=UTF-8" but, with latest 1.5.2 mediawiki server, Content-Type is return with a lowercase t: Content-type. Patch consists in allowing both situations. In Client.pm, please patch with something like th e patch enclosed.
Cheers,
Nicolas
--- Client-ori.pm 2005-06-04 14:54:15.000000000 +0200
+++ Client-new.pm 2005-11-16 18:45:02.000000000 +0100
@@ -1392,7 +1392,8 @@
my $p = HTML::TokeParser->new(\$doc);
while ( my $t = $p->get_tag("meta") ) {
next unless defined $t->[1]->{'http-equiv'}
- and $t->[1]->{'http-equiv'} eq 'Content-Type';
+ and ($t->[1]->{'http-equiv'} eq 'Content-Type'
+ or $t->[1]->{'http-equiv'} eq 'Content-type');
my $cont = $t->[1]->{'content'};
$cont =~ m/charset=(.*)/;
return $1;