Radio Button make a table or cells appear

K

Kevin Hanlon

Hi new to frontpage ...
I would like to use a radio button
Yes/no that if 'yes' is picked a table appears
to accepet additional information
 
R

Rick Budde

Not possible with the standard Front Page form handler.

You would have to program such functionality using
whatever programming language that is supported by your
host.
 
M

MD Websunlimited

Hi Kevin,

Very easy to accomplish with a layer (DIV) but I would recommend using a check box instead of radio buttons.

In the form create a div and give it an id value of "Optional" and a style of display: none. Next create the table of optional
information inside of the div.

<div id="Optional" style="display: none;" >
<table>
....
</table>
</div>

Use an onclick event handler for the check box like so:
<input type="checkbox" value="V1" name="R1" onclick="if(this.checked) {Optional.style.display = 'block' } else
{Optional.style.display = 'none';}" >Optional Information

Now when you click and check the check box it will display the hidden fields.

Note, the optional fields will be sent as a part of the form in all cases. It is up to you to determine from the check box whether
the visitor wished to have the optional information gathered.

You may see an example of this at http://www.fpplus.com/samples/optional_information.htm
 
Top