If the visible of a server side control is set to false, even I know it’s id, is that possible to know that it is invisible by using jQuery? what code should I use, say the control id=”test1″.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Or
:hidden: http://api.jquery.com/hidden-selector/displayproperty of the element to see if it is set tonone(hidden…)The
:hiddenpseudo-selector checks the following:If setting the element
visible = falseon the server-side makes the element not included in the DOM then you can check for the existance of an element with this:.lengthwill return the number of elements found, since we are selecting with an ID we know only one can be returned, so if.lengthreturns zero then the object doesn’t exist and if it returns one then it does.