mmarif4u Posted March 22, 2007 Share Posted March 22, 2007 hi guys this is a simple question but out of mind this time... i have a dropdown on my one page it have 6 choices for example(1,2,3,4,5,6) when a user select 3, then 3 textboxes appaer where they fill it, if 2 then 2texbox and so on... i know that javascript can do it, but how bcoz i am good in js. this is the dropdown button code. <tr> <td align="right"> <p>No. of cildren :</p> </td> <td align="left"> <select class="textbox2" name="child"> <option value="1">1</option> <option value="2">2</option> <option value="3" selected="selected">3</option> <option value="4">4</option> <option value="5">5</option> <option value="6">6</option> </select> <font color="black" size="3"><tt><b>*</b></tt></font> </td> </tr> Can any one point me some good stuff. Any help will be appreciated. Thanks. Link to comment https://forums.phpfreaks.com/topic/43801-simple-question/ Share on other sites More sharing options...
skali Posted March 22, 2007 Share Posted March 22, 2007 Haven't tried it but may be you can assign an id to the <td> where you want to add fields. Then get reference to it using : var td = document.getElementById('id_of_td'); td.innerHTML = 'what so ever...'; Link to comment https://forums.phpfreaks.com/topic/43801-simple-question/#findComment-212651 Share on other sites More sharing options...
mmarif4u Posted March 22, 2007 Author Share Posted March 22, 2007 Thanks skali for reply. It means that i have to make 6 textbox with labels, then assign id for every one but one thing more this id will be unique or by sequence, 2nd how it will depend on the dropdown. Link to comment https://forums.phpfreaks.com/topic/43801-simple-question/#findComment-212654 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.