I'm trying to toggle the visibility of a form element using jQuery. I have a flipswitch widget and am setting it's class with either the class='reviewControls' or data-wrapper-class='reviewControls' attributes, as can be seen in this fiddle. The problem is that it's working in the fiddle, but not in my code. My code hides the <label> field but not the <input> field. I'm finding it hard to debug as jQuery adds style="display: none; to the <label> element but leaves the <input> element (and it's styles) unchanged. Any ideas?
Toggle visibility of a form element
208 views Asked by Brad At
1
There are 1 answers
Related Questions in JQUERY
- In Datatables, start value resets to 0, when column sorting
- Bootstrap modal not showing at the desired position on a web page when the screen size is smaller
- window.location.href redirects but is causing problems on the webpage
- Using JQuery Date Slider
- Storing selected language in localStorage
- How to stop other divs from still showing when i click a different button?
- Check multiple values with jQuery
- Bootstrap component does not want to render in Datatables function
- put white spaces when entering an amount moneytype symfony
- Trouble accessing custom header in AJAX response using jQuery in Fiware Keyrock
- I just cant make it work, HTML, JS and Firebase error
- Didn't declared variable still not getting any error in JavaScript
- Move element horizontally while scrolling vertically in pure JavaScript
- allow multi carousel in same page
- Embedded TikTok posts / thumbnail styling issue
Related Questions in CSS
- How to use custom font during html to pdf conversion?
- Storing the preferred font-size in localStorage
- mp4 embedded videos within github pages website not loading
- Is there any way to glow this bulb image like a real light bulb
- What can I do to improve my coding on both html and css
- Uncaught TypeError: google.maps.LatLng is not a constructor at init (script.js:7:13)
- Bootstrap modal not showing at the desired position on a web page when the screen size is smaller
- How to increase quality of mathjax output?
- Hover animation resetting( seemingly reverting back to original CSS and then again to hover)when moving mouse horizontaly accross a part of an element
- Storing selected language in localStorage
- How to clip grid cell and provide scroll as well?
- KeyboardAvoidingView makes a messy the flexbox
- Rotate an object around another object in javascript
- Understanding Scroll Anchoring Behavoir
- how to use only block layout in this css code?
Related Questions in VISIBILITY
- CRTP Member Visibility
- Detect browser out of focus
- How do I hide an entire HTML page, but make the page still renders and still exist?
- Issue WPF Datagrid maybe bug?
- PHP Error: Cannot access private property
- SSRS Hide Columns Based on Time Expression
- Unity setactive() not working because of object name
- Dynamically Hiding Empty Sections of List in SwiftUI
- Override HTML element visibility controlled by a <details> tag
- How to remove symbols directly from a dynamic library binary(.so)?
- I'm trying to make this a randomly visible and clickable small link button. How can I make this work?
- Feeds List having text, image and video with auto Play/Pause on Scroll in Flutter
- how to add a toggle for visibility in theme my login WP plugin
- How to make a child widget added in a slot visible?
- Visibility Hidden Safari Bug
Related Questions in SHOW-HIDE
- Show/hide text using getElementsByClassName for all classes
- Button hide based on author in elementor
- Excel VBA hide/Unhide Rows
- Hide all elements when the one element is visible
- How can I hide and show the menu well so that it doesn't look messed up?
- Hide and show span element by clicking div element?
- Hidden text boxes show on exporting SSRS report to Excel
- How to show and hide password when click on eye icon using jQuery and also both the password (new and confirm) should be matched
- Show Hide a div based on selected option value of a select using JS
- How to Remove Class from Current and Add to Next Element with JS Only?
- When I tap and immediately type, the UITextField freezes, but if I tap it then wait, type works
- How to show and hide multiple divs as I click the respective button with only JavaScript?
- Show/hide rows and sheets based on other cell values
- How to hide pages in a streamlit multiple page app?
- How to specify only the id of the appearing text, without specifying the ids of the hiding texts?
Related Questions in JQUERY-MOBILE-FLIPSWITCH
- MS Visual Studio Lightswitch flipswitch control sometimes does have displayed default value
- Toggle visibility of a form element
- Apparent bug when combining jQuery Mobile, jQuery UI, and data-role=flipswitch. How to fix?
- How to get the value of a checkbox flipswitch in JQuery Mobile 1.4.5?
- Flipswitch in lightswitch is going in an infinite loop
- Listview duplicates ID on adding list item Jquery Mobile
- How to right align a flipswitch in jquery mobile 1.4.5
- Add Value to flip toggle switch
- Jquery mobile dynamically add flipswitch to page
- Jquery Flipswitch toggle for webapplication
- How to make this flipswitch work based on value of mysql using php
- JQueryMobile: Load pages with Flip toggle switch
- jQuery Mobile with touchmove event
- cannot call methods on flipswitch prior to initialization
- FlipSwitch jQuery mobile constructor
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Popular Tags
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
I couldn't seem to solve this problem, but wrapping the element in another
<div>and then hiding that new<div>solved the problem.