[Perl] Identification problème de Parse UTF-8

Identification problème de Parse UTF-8 [Perl] - Perl - Programmation

Marsh Posté le 19-02-2006 à 20:56:57    

Bonjour à tous, j'ai un problème en perl, je veux me loguer à un site en utilisant MECHANIZE, le script fonctionne chez un amis sous windows mais pas chez moi sous linux (debian).
Voici le code :

Code :
  1. #!/usr/bin/perl -w
  2. use strict;
  3. use WWW::Mechanize;
  4. use Data::Dumper;
  5. #Déclaration des variables
  6. my $url = 'http://projecthack.projectnews.fr/index.php';
  7. my $hashcode;
  8. my $hashcode2;
  9. my $bot = WWW::Mechanize->new;
  10. # page de login principale et identification
  11. $bot->get( $url );
  12. $bot->form_number(1);
  13. $bot->set_fields( login => 'psyphi', password => 'jevaispasledonnerici' );
  14. $bot->submit;
  15. $bot->get('http://projecthack.projectnews.fr/coding/Parse.php');


 
Voici les erreurs, j'ai fais des recherches sur internet mais je n'ai rien trouvé de concret:

Code :
  1. Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/share/perl5/LWP/Protocol.pm line 114.
  2. Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/lib/perl5/HTML/PullParser.pm line 83.
  3. Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/lib/perl5/HTML/PullParser.pm line 83.
  4. Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/lib/perl5/HTML/PullParser.pm line 83.
  5. Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/share/perl5/LWP/Protocol.pm line 114.
  6. Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/lib/perl5/HTML/PullParser.pm line 83.
  7. Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/lib/perl5/HTML/PullParser.pm line 83.
  8. Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/lib/perl5/HTML/PullParser.pm line 83.
  9. Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/lib/perl5/HTML/PullParser.pm line 83.
  10. Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/lib/perl5/HTML/PullParser.pm line 83.
  11. Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/lib/perl5/HTML/PullParser.pm line 83.


Les erreurs ne viennent pas du code mais de perl je crois, mais je ne sais pas comment le configurer.
Merci d'avance pour votre aide.

Reply

Marsh Posté le 19-02-2006 à 20:56:57   

Reply

Marsh Posté le 20-02-2006 à 11:34:26    

quelle est ta version de perl ?
perl ne gere correctement l'utf8 que depuis 5.8 (et encore)

Reply

Sujets relatifs:

Leave a Replay

Make sure you enter the(*)required information where indicate.HTML code is not allowed