473,324 Members | 2,370 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

Show hide depending on the value of a select

Hello,
I have a form with multiple seizures which to choose between various input occurrences in radio (only one choice possible). I would hope that if the user selected in a particular ca do that automatically appear in a form more in my jsp page
eg:
1 choice []
2 choice []
3 choices []
If you chose option 1 or option 2 ca just displays:
the value of the choice

If you chose option 3 ca automatically add:

Systolic: | ______ |
distolique: | ________ |
Lice: | _________ |
temperature: | _________ |

I tried with
Expand|Select|Wrap|Line Numbers
  1. etape2forward function () {
  2. $ ("# Etape2_forward"). Click (function () {
  3.  
  4. if ($ ("[name = 'etatVisuel']: checked") val () = 4.!)
  5. {
  6. $ ("# Systolic") hide ().
  7. $ ("# Digsystolique"). Hide ()
  8. $ ("# Lice"). Hide ()
  9. $ ("# Temperature"). Hide ()
  10. $ .ajax ({
  11. url: '/ GHopital / emergency / save'
  12. Type: 'POST'
  13. data: {"idPatient": $ ("# idPatient") val ().
  14. "EtatVisuel": $ ("[name = 'etatVisuel']: checked") val ().
  15.  
  16. },
  17. success: function (idUrgence) {
  18. window.location = "# / emergency / read /" + idUrgence;
  19. }
  20.  
  21. });
  22.  
  23.  
  24.  
  25.  
  26. }
But it does not work unfortunately.
Jul 4 '15 #1
1 1507
Dormilich
8,658 Expert Mod 8TB
check your error console. there are lots of syntax errors happening.

PS. you have additional spaces all over the place causing HTTP and CSS errors as well.
Jul 4 '15 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

6
by: Steve Speirs | last post by:
Hi I'm trying to show/hide a simple piece of text and a text field on a form based on what choice is made from a drop down box. <select name="dropdown" size="1"> <option selected...
3
by: earl | last post by:
Hey Say I have two <form> on a page like this : <form action="private.asp" method="post" name="form1"> // code <input type=submit value="submit" name="submit"> </form> <form...
9
by: sergio | last post by:
Hi all, I have created the following script that will show/hide a menu based on checkboxes. It works fine in Opera but not on IE6! Does anybody knows a workaround this problem? Thanks for your...
2
by: jeet_sen | last post by:
Hi, I have created a table colelcting data from an XML source. After I built the whole table I ahve given user options to filter out columns from the table. For this I have collected all the...
1
by: asilverpeach | last post by:
Hey Guys! Found some great scripts here on this topic but have to make to changes to the code that I can't seem to figure out. First, In the following code clicking on the headers shows the...
6
by: Norman | last post by:
Hello, I have a working Show / Hide form, that works on FF, but what I would like to do is to be able to display one part when a user clicks on one radio button and display another part when the...
2
by: Scott McNeill | last post by:
I have created a form with show/hide on a couple of fields. However, this hidden info is not posting back when I click submit. Can someone help? Source code <?xml version="1.0"...
5
by: SValencia | last post by:
Hello my name is Steve and I am a newbie....almost. I have been working at learning html, graphics and css in my spare time. I have a site at www.ContractorInsurance.net. Yes, I am an...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.