HTML - Forms : Check Box That Enables 2 Radio Btns And A Text Field
Apologies in advanced if this has been solved in another forum.
I found my answer googling around but i need it refined. One checkbox with two disabled radio buttons. When user clicks on check box it enables both radio buttons and a input text field. Code: <script type="text/javascript"> function enable(x){ if(x.checked){document.formTest.rRegular.disabled=0} else{document.formTest.rRegular.disabled=1}} </script> </head> <body> <form name="formTest" method="POST" action="--WEBBOT-SELF--"> <p><input type="checkbox" name="cbFlower" value="ON" onClick="enable(this)">Flowers</p> <p><input type="radio" checked name="rRegular" value="V1" disabled=1>Regular Package <input type="radio" name="rDeluxe" value="V2" disabled=1>Deluxe Package</p> <p><input type="text" name="tFlower" size="40" disabled=1></p> </form> I'm sure its a simple modification to the 'funciton enable' so that it enables the other radio button and text box. I need to repeat this process for other groups of similiar check boxes with 2 or more radio buttons and a text field. They need to be independent of each other. If this one get's solved I can copy the function and modify it for the other groups. Unless there's a simpler way. Thanks for your help Similar TutorialsHi I'm trying to add an update profile page on my site and am uploading the details from a database. I want to display the details in a form where there will have the option to click an update button the problem is: i have a radio button where I want it to automatically show the current sex of the member, but how to I determine which box to check and which one to leave? the sex is stored in the database in a enum, values 'male', 'female' the html I've got at the moment is: HTML Code: Male: <input type="radio" name="male" <?php if ($msex = "male") {echo "checked";}?>/> Female: <input type="radio" name="female" <?php if ($msex = "female") {echo "checked";}?>/> As this is more than likely a v. dumb question... (I've possibly asked dumber before) Apologies but... Does anyone know if you can amend to "add to cart buttons" from paypal? Every time I amend to <form> code my cart goes on the fritz. All I really want to do is change it from the .gif to a hyperlink... thx in advance... I want to be able to use radio buttons on my form but I need the selected one to update 2 seperate fields in my database. I am attaching what I have tried, but didn't work. I am new to all of this, so please be gentle HTML Code: <INPUT class="element radio" id=element_5_1 type=radio value=Swee****er Golf and CC=Ub2venue> <input type="hidden" name="Ub2bwsdate" value="10/22/2008"/> <LABEL class=choice for=element_5_1>Oct. 22 6:30p.m. Swee****er Golf and Country Club, Apopka </LABEL> <INPUT class="element radio" id=element_5_2 type=radio value=Swee****er Golf and CC=Ub2venue> <input type="hidden" name="Ub2bwsdate" value="10/23/2008"/> <LABEL class=choice for=element_5_2>Oct. 23 2:30p.m. Swee****er Golf and County Club, Apopka </LABEL> <INPUT class="element radio" id=element_5_3 type=radio value=USBank, KC=Ub2venue> <input type="hidden" name="Ub2bwsdate" value="10/28/2008"/> <LABEL class=choice for=element_5_3>Oct. 28 2:30 p.m. USBank, Kansas City </LABEL> <LABEL class=choice for=element_5_4></LABEL> </SPAN> I need it to update field Ub2venue with the locaion and update the Ub2bwsdate field with the date from the selected one. Any help would be appreciated. anyone know a code that enables you to write over a image because right now i had to use my header and nav as a backround (because there pictures) is there anyway i can write text over a picture? thanks alot heres my website for reference, (the only reason the letters are on the nav bar is because i set it as a backround) someone please help www.seattlewest.net Hey I've got an issue and it's driving me nuts trying to figure it out. I have a form and when it's submitted from the webpage, the resultant email has no name in the from field. Using the below example, the email would say From: joe@home.com () The empty parenthesis is the issue, but I haven't been able to figure out how to get a name in there! I've searched through these forums, as well as a number of other sites including the teaching area of www.w3.org. Help!!!! Thanks Paul Below is the html I'm using. <html> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <form action="/cgi-bin/formmail/formmail.pl" method="POST"> <input type="hidden" name="redirect" value="http://www.whatever.com/thanks.html"> <p> <input type="hidden" name="recipient" value="joe@home.us"> <input type="hidden" name="subject" value="just testing"> </p> <HR noshade size=5 WIDTH="95%" ALIGN="CENTER"> <br> Your name: <input name="name" size=30 maxlength="30"> <br> Your e-mail address: <input name="email" size=30 maxlength="30"> <br> Location <input name="location" size=30 maxlength="90"> <br> <br> Message/comments: <br> <textarea wrap=physical name="Message/comments" cols=60 rows=8></textarea> <br> <br> <input type="submit" value="send email" name="submit"> <input type="reset" value="clear" name="reset"> </form> </body> </html> Hello, I'm fairly new to HTML and scripting and could use some help. I'm setting up an HTML form with a CGI script (script1) and submitting data to another CGI script (script2) with the POST method using enctype="application/x-www-form-urlencoded". I create my form page with script1 based upon files and it will create a number of check boxes. My problem is that I do not know exactly how many check boxes are created. If they are checked they submit a value, however, if they are not checked, they are not listed in the Query String. So script2 does not know if there is an unchecked check box after the last checked one. Is there an option or a different enctype that will submit their value with a NULL string if they are not checked? Or is there any other way to get around this issue? Any Help you can give me is greatly appreciated. Thanks in advance Hi Can any one help. I have this form the user is ask to input a message and a number. I want to be able to add a line of text to the message, which the user can not delete. But is sent joined to the message. ie User input Message = "Hi Just would like to share this site with you" with added text: Message "Hi Just would like to share this site with you" + "mydomain.com" Can anyone help? =========================================== Here is my form so far <script language="javascript" type="text/javascript"> function limitText(limitField, limitCount, limitNum) { if (limitField.value.length > limitNum) { limitField.value = limitField.value.substring(0, limitNum); } else { limitCount.value = limitNum - limitField.value.length; } } </script> <html> <body> <form action="stext.php" method="POST" name="number" id="number" style="width: 384; height: 372; "> <input name="number" type="text" id="number" style="position: absolute; left: 123; top: 287; color: #FFFFFF; width: 154px; border: 1px solid #ACC61B; background-color: #000000" size="20" tabindex="2"><p style="margin-top: 0; margin-bottom: 0"> <textarea name="message" cols="17" rows="1" id="message" onKeyDown="limitText(message,countdown,140);" onKeyUp="limitText(message,countdown,140);" style="position: absolute; left: 120; top: 105; width: 162px; height: 154px; color: #FFFFFF; font-family: Agency FB; font-size: 14pt; border: 1px solid #ACC61B; background-color: #000000" tabindex="1"></textarea> <br> </td> <input name="Submit" type="submit" id="Submit" value="!" style="position: absolute; left: 121; top: 329; color: #D95503; width: 157px; height: 23px; border: 1px solid #D95503; background-color: #D95503" tabindex="3"></p></form> <p style="margin-top: 0; margin-bottom: 0"><font size="4" face="Agency FB">Maximum characters: 140. You have <input readonly type="text" name="countdown" size="3" value="140"> characters left.</font> </font></p> <p style="margin-top: 0; margin-bottom: 0">nmgnm,</p> </body> I want to create a simple form that asks for your name, k? Thats easy, but how do I make it so when the person clicks "Submit" it says "Thank you" then I can go to http://(website).com/names to see all the names that someone put. Please help me out here. Hi all, I would like to ask for your help here. How can I first have a few radio buttons on my page and when the user select one of those, a text box with a submit button will appear. The text box is for the user to key in some kind of code/password so that it will prompt the user to a url according to the code/password. Example: Code: YAH URL: www.yahoo.com Code: GOO URL: www.google.com And if the user keys the wrong code it will prompt a message box asking them to try again. If the user key the code wrongly for 3 times it will prompt to another url. Ive also attach an example of how it should look like. I would appreciate for your help. Thanks a lot! at the moment the text is white and the background of the data area in the form is white too meaning people can't see what they type in. can someone please help so that they can see what they are typing in? here's the webpage; http://www.myspace.com/blissneso and here's the code; <BR><BR><form method="post" action="http://www.ymlp.com/subscribe.php?blissneso"> <table border="0"> <tr> <td colspan="2"><img src="http://img404.imageshack.us/img404/9911/tile18gk.jpg" alt="title" /></td> </tr> <tr> <td>Name:</td> <td><input type="text" name="YMLP0" size="20"></td> </tr> <tr> <td>Email:</td> <td><input type="text" name="YMLP1" size="20"></td> </tr> <tr> <td colspan="2">Select your location:</td> </tr> <tr> <td>NSW:</td> <td><input type="checkbox" name="CAT2"></td> </tr> <tr> <td>VIC:</td> <td><input type="checkbox" name="CAT3"></td> </tr> <tr> <td>QLD:</td> <td><input type="checkbox" name="CAT4"></td> </tr> <tr> <td>WA:</td> <td><input type="checkbox" name="CAT5"></td> </tr> <tr> <td>SA:</td> <td><input type="checkbox" name="CAT6"></td> </tr> <tr> <td>TAS:</td> <td><input type="checkbox" name="CAT7"></td> </tr> <tr> <td>ACT:</td> <td><input type="checkbox" name="CAT8"></td> </tr> <tr> <td>NT:</td> <td><input type="checkbox" name="CAT9"></td> </tr> <tr> <td>NEW ZEALAND:</td> <td><input type="checkbox" name="CAT10"></td> </tr> <tr> <td>OTHER COUNTRY:</td> <td><input type="checkbox" name="CAT11"></td> </tr> <tr> <td colspan="2"><input type="submit" value="Submit"></td> </tr> </table> </form> thanks for any help in advance!!! Is it possible to set up a form so that the text that a person enters in a text line disappears when they hit the send button? That would make the text line instantly ready for the next entry, without the user having to erase the old entry first. Or do you need something like Javascript to do that? can someone help me with a script basically i want an input box where u put ur name into. then u click submit then on the next page it displays what u just put in the input box...how do i do it? Hello, I'm trying to create a text field on my site, and I want that when a user enter his zip code, and then press enter, he will be directed to another website. But it doesn't work: <input type="text" name="zipcode" value="Enter your Zip Code" id="zip" maxlength="20" onclick="window.location.href='http://second.site.com'"> Thanks Steve How can i chnage the text color of the disabled field. Style attribute is not working I have a problem; Look at this; {a text field} <iframe id="iframe1" src="google.com/gog.html? + the letters in the text field"> My problem is to get the src in the iframe to be google.com/gog.pl? + the letters in a text box anywhere on my site. {google.com was just an example} Do you know this better than me? Hi everyone, Hoping someone might be able to help me - I'm a Latin teacher, trying to design a website for my students to practise their verb conjugatiosn and noun declensions, so what I'm wondering is how I have, for example, a grid with text boxes for students to write the correct endings in and then a submit button which then checks what the student has written in the box and then maybe a pop up window appears saying "you have got 2 endings wrong, try again" or something like that... any ideas? I got as far as looking at forms but couldn't work out how to adapt them to the purpose I'm looking for. Would be very grateful for some help on this! PinguisIuvenca I every one I'm working on a page where the text is set up in HTML and I'm getting some pretty different results on different computers. This really is a 2 parted question. First if you would be so kind as to visit this page and tell me if the text is properly sized and formatted as to fill the areas between the images: http://www.reelectjusticecliffordtaylor.com/bio.html I've included a screen grab of what the text looks like on my PC when I see it live. at this link: http://www.johncliffordtaylor.com/text_example.jpg Second base on what I've seen up to this point I would like to know if there is a way to get the text to appear more uniformly in different browsers on different PC's. So far I'm just working with: body,td,th { font-family: Geneva, Arial, Helvetica, sans-serif; font-size: 16px; color: #2B24A6; (pretty much navy) } that are embedded right inside my page HTML page. So I'm very open to any ideas on how to get the text to appear more consistently across many computers and browsers. Thx for the help every one! John Hi Guys I have a text input field in a form that has data in it from a previous entries. Is there something i can do that ensures the field is empty when the form is pulled up? Thanks everyone Hello, I am making a check-in on my site. People have a number they recieve, what I want to do with this number is make a texfield and when the clicker presses Go! it does: http://www.cloudvairlines.com/index....redintextfield If anyone could make a code for this I would really really appreciate it. I have already tried some but none of them work! I am trying to develop a login page with Photoshop and Dreamweaver. I have spliced out my images from Photoshop and placed them in Dreamweaver. I attempted to delete the image of a text field and replace it with an actual text field input, but when I do that the picture becomes distorted. Here is the picture of the site with just the pictures and no text field: Here is the picture of the site with text field added where the image of a text field was: Any help would be appreciated. |