Solved

Hide disabled drop down

Posted on 2014-02-06
5
257 Views
Last Modified: 2014-03-12
I need to hide disabled drop down. The problem is I have I have 2 variables if the drop down is disabled i ma using the hidden form variable but the drop down itself need to be hidden

if I do this it probably taking the hidden form variable.

$("#triggerSeed2").parent().hide();

the reason I doing it this way because under certain condition the drop down will be disabled, but other fields are still using the value from it. I thought if I disable the drop down and enable the hidden form variable that will work and it does but i need a way of hiding the drop down
0
Comment
Question by:erikTsomik
5 Comments
 
LVL 58

Expert Comment

by:Gary
ID: 39839175
Doesn't matter if it is hidden or disabled you can still get the selected value from it.
Anything other than that I am not understanding.
0
 
LVL 19

Author Comment

by:erikTsomik
ID: 39839732
But I can not hide the  disabled drop down
0
 
LVL 58

Expert Comment

by:Gary
ID: 39839748
Post your code. There is no reason you cannot hide it. Maybe you are targeting the wrong element.
Here's a simple example.
http://jsfiddle.net/3nq89/
0
 
LVL 9

Expert Comment

by:Sar1973
ID: 39841472
To show/hide: document.getElementById("myCombo").style.display="inline"/"none";
To enable/disable: document.getElementById("myCombo").disabled=true/false;
0
 
LVL 2

Accepted Solution

by:
DualCool earned 500 total points
ID: 39860594
instead of hiding the parent

$("#triggerSeed2").parent().hide();

try giving the parent an ID and hide it directly

$("#triggerSeed2_parent").hide();
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
In this tutorial viewers will learn how add a scalable full-width header using CSS3. Create a new HTML document with an internal stylesheet. Set a tiled background.:  Create a new div and name it Header. Position it with position:absolute at the top…
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…

943 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now