...

View Full Version : Making Form Fields Appear or Disappear,Based on the Value of other Fields



TechnoAtif
01-10-2008, 06:03 AM
Here is the other one..This requires a textbox to open while clicking of a radiobutton in one part and in the other part on the click of a list/menu.

I want that..as I click the second radiobutton,the textbox be displayed so that the data may be posted.else itremains hidden or engraved..and a similar other problem with list/menu in place of rado button.

Tablename:form
Columnames : (i) des,des_url
Columnnames: (ii)dom,domname



<form action="<?php echo $_SERVER['PHP_SELF'];?>" method="post" >
<table width="90&#37;" align=center cellpadding=2 class=medium>
<tbody>
<tr bgcolor=#42519c>
<td colspan=2><font color="#FFFFFF" size="1" face="Verdana, Arial, Helvetica, sans-serif"><strong>1. Type of Web Site </strong></font></td>
</tr>
<tr>
<td width="42%"><font color="#333333" size="1" face="Verdana, Arial, Helvetica, sans-serif"><br>
<input type=radio name=design value=New_Web_Site />
New Web site design </font></td>
<td width="58%" rowspan=2><font color="#333333" size="1"
face="Verdana, Arial, Helvetica, sans-serif"><br>
</font> </td>
</tr>
<tr>
<td><font color="#333333" size="1" face="Verdana, Arial, Helvetica, sans-serif"><br>
<input type=radio name="design" value=Re-design />
Re-design a Web site</font></td>
</tr>
<tr>
<td width="42%"><font color="#333333" size="1"
face="Verdana, Arial, Helvetica, sans-serif"><br>
If re-design, what is the URL?&nbsp; </font></td>
<td valign=bottom><div align=right><font color="#333333" size="1"
face="Verdana, Arial, Helvetica, sans-serif"><br>
<input maxlength=80 size=50 name=des_url >
</font></div></td>
</tr><tr>
<td class=ws_body valign=top colspan=2><font color="#333333" size="1"
face="Verdana, Arial, Helvetica, sans-serif">Do you have a Internet Merchant Account?</font></td>
<td class=ws_body valign=top><font color="#333333" size="1"
face="Verdana, Arial, Helvetica, sans-serif">
<select name=ima>
<option selected>Select</option>
<option value=yes>Yes</option>
<option value=no>No</option>
<option value="not sure">Not Sure</option>
</select>
</font></td>
</tr>
<tr>
<td class=ws_body valign=top width="18%"><font color="#333333" size="1"
face="Verdana, Arial, Helvetica, sans-serif">If yes, with what company <br>
(WorldPay, PaySystems, etc)?</font></td>
<td class=ws_body valign=center colspan=2><div align=right><font color="#333333" size="1"
face="Verdana, Arial, Helvetica, sans-serif">
<input maxlength=500 size=50 name=imabank>
</font></div></td></tr>
</tbody>
</table>
</form>

Iszak
01-10-2008, 06:41 AM
You're looking for the javascript section not the PHP section. I think this is what you're looking for but it's not with the radio buttons.
http://www.dynamicdrive.com/dynamicindex1/chainedmenu/index.htm



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum