Thanks for everyone's replies. I tried HTTP::Request::FromTemplate because that looked easiest but for some reason the request wasn't getting sent.
The last suggestion is semi-working for me in that the request is getting sent and the browser goes to the site, but I'm not actually getting the desired page.
I just wanted to check if I've set this up right with regards to the viewstate content below?
my $url = 'http://lhtbod-apdhz001.uk.ad.com/ess/SignUpAsEmployee.aspx'
+;
my $content='__VIEWSTATE=dDwxNTk4MDgzOTc1O3Q8O2w8aTwyPjs%2BO2w8dDw7bDx
+pPDE%2BOz47bDx0PDtsPGk8Mz47aTw1Pjs%2BO2w8dDxwPHA8bDxUZX
h0Oz47bDxBZG1pbmlzdHJhdG9yOiA3NTIzNTk7Pj47Pjs7Pjt0PHA8cDxsPFRleHQ7Pjts
+PDIyLzEyLzIwMDUgMTU6MTc7Pj47Pjs7Pjs%2BPjs%2BPjs%2BPjs%2
BBfgZ5IQIMSNKJj7%2BLszqPx1I1Co%3D&txtEmployeeID=84212&BtnSignUp=Sign+U
+p';
my $req = POST $url,
[ 'Host' => 'lhtbod-apdhz001.uk.ad.com',
'User-Agent' => 'Mozilla/5.0 (Windows; U; Windows NT 5.1; e
+n-US; rv:1.8) Gecko/20051111 Firefox/1.5',
'Accept' => 'text/xml,application/xml,application/xhtml
++xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0
.5',
'Accept-Language' => 'en-us,en;q=0.5',
'Accept-Encoding' => 'gzip,deflate',
'Accept-Charset' => 'ISO-8859-1,utf-8;q=0.7,*;q=0.7',
'Keep-Alive' => '300',
'Connection' => 'keep-alive',
'Referer' => 'http://lhrbod-apdhz001/ess/SignUpAsEmploye
+e.aspx',
'Content-Type' => 'application/x-www-form-urlencoded',
'Content-Length' => '309',
'Content' => $content,
];
|