I want to create a form parameter set for use in HTTP POST on the fly, but I'm not sure how to access the LWP :: UserAgent data structure dynamically.
In a typical code example, this structure is passed as a request.
my $response = $browser->post(
'http://example.com/postme',
[
'param1' => 'value1',
'param2' => 'value2'
],
);
I have a set of parameter names and values stored in a hash, and I want to build the structure in square brackets from my hash data. What is this structure and how can I do what I want? (as you can tell, I'm not a perl expert!)
source
share