Dear all

Im using HTTP::Request::Form to submit to a cgi link online.

Its going well, but I've come up against multiple checkboxes with the same name unfortunately:

<div class="database_category">Citation Databases:</div> <div class="edition"> <input type="checkbox" name="editions" checked value="D"> <a href="" onClick="return show_help( 'http://wos4.isiknowledge.com:80/LinkOut.cgi?dest=help/h_database.htm% +23sci&origin=http%3A//wos4.isiknowledge.com/CIW.cgi%3FSID%3DQVR5kArh@ +WcAAGvMDrs%26Func%3DGoBack');"> <img class="binfo" src="Images/info.gif" name="Information" alt="Information" title="Information" /> </a> Science Citation Index Expanded (SCI-EXPANDED)--1955-present </div> <div class="edition"> <input type="checkbox" name="editions" checked value="S"> <a href="" onClick="return show_help('http://wos4.isiknowledge.com: +80/LinkOut.cgi?dest=help/h_database.htm%23ssci&origin=http%3A//wos4.i +siknowledge.com/CIW.cgi%3FSID%3DQVR5kArh@WcAAGvMDrs%26Func%3DGoBack') +;"> <img class="binfo" src="Images/info.gif" name="Information" alt="Information" title="Information" /> </a> Social Sciences Citation Index (SSCI)--1956-present </div> <div class="edition"> <input type="checkbox" name="editions" checked value="H"> <a href="" onClick="return show_help('http://wos4.isiknowledge.com: +80/LinkOut.cgi?dest=help/h_database.htm%23ahci&origin=http%3A//wos4.i +siknowledge.com/CIW.cgi%3FSID%3DQVR5kArh@WcAAGvMDrs%26Func%3DGoBack') +;"> <img class="binfo" src="Images/info.gif" name="Information" alt="Information" title="Information" /> </a> Arts & Humanities Citation Index (A&HCI)--1975-present </div>
According to HTTP::Request::Form, the only value sent to the cgi link for 'editions' is the last one 'H' even if they were all checked. This is confirmed in a dump of the form:
FIELD{input/checkbox} editions=H FIELD{input/checkbox} editions=H FIELD{input/checkbox} editions=H
It was to my delight, that I realised that the checkboxes do have multiple values, much like radio buttons, but I can't access these different values via HTTP::Request::Form

So I want to fall back onto HTTP::Request::Common, which will enable me to submit any value to any field name, but my question is

What value should I send, if I wanted to indicate all the checkboxes were checked?
Should I just send 'DAH', and expect the cgi script to pasrse for all three values, or do I need a seperator?

Any help would be appreciated

Thanks
Sam

Updated Steve_p - Edited code so it wasn't all on one line


In reply to Checkboxes with the same name by seaver

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.