'simple posting'

Nick Chirca (terra@vl.ro)
Mon, 6 Nov 2000 15:20:18 +0200 (EET)


I have an account on www.blackplanet.com which I made for learning how to
use POST methods (filling in text areas). The username is: lwp_test and
the password is: perl-lwp  !

If you manually connect to the site, and fill into the 'remember me'
checkbox, then the blackplanet site will recognize you. So if you login
manually, let's say from lynx, then if you build a post script with lwp,
it should have no problems with authentification.

So, I tried to login manually and then build a script to send me a note to
the other account that I have on blackplanet, which is
: dreamer_wolf. Unfortunately, I have no success... Can you take a look at
the code and tell me what is wrong ? A 'code that works' will be
appreciated.

#! /usr/bin/perl -w
#-----------------------------------------------------------------
use LWP::UserAgent;
use HTTP::Request::Common;
my $ua = LWP::UserAgent->new;
$ua->env_proxy;
use HTTP::Cookies;
$ua->cookie_jar(HTTP::Cookies->new);
$ua->request(GET "http://members.BlackPlanet.com/dreamer_wolf/"); 
#to set cookies
$ua->request(POST "http://Notes.BlackPlanet.com/sendnote.html", [
  "MEMBER" => "dreamer_wolf", # hidden
  "SUBJECT" => "Test 1 from within Perl",
  "MESSAGE" => "If you get this, the script works,"
              ."Bla-bla-bla\n\n"
              ."Nick",
  "SENTMESSAGES" => "0", # checkbox
],
  Referer => "http://members.blackplanet.com/dreamer_wolf/",
); 


#---------------------

Can somebody help me ?


-- 
Nick...
____________________________________________________________________________
Go to my main website http://terra.vl.ro/nick/ and find out more about me.
I am seeking a job ! See http://terra.vl.ro/nick/resume.html to read
about my skills and experience.
MAY ALL OUR CHOICES BE GOOD ONES !
_____________________________________________________________________________