I am using the latest version of jquery mobile and my problem is that I have given a submit button an ID and then added some css to set the ID to display:none;
For some reason this does not work.
Has anyone had this problem before?
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.
It’s hard to tell what you’re trying to do without any code but I think the problem stems from the fact that jQuery Mobile doesn’t style your existing button but rather, hides the element and wraps it in a new
divwhich is styled to look and behave like a button.The current jQuery Mobile markup for a button looks like this:
So you look for the closest ancestor with the class
ui-btnand hide it:If there’s a better way to do this, I’d love to know about it. Here’s a fiddle that shows my solution in action.