javascript - jQuery CheckAll Toggle Not Quite Working Correctly -


का प्रयोग:

  फ़ंक्शन चेकटॉगल (जो) {jQuery (जो) .each (फ़ंक्शन () {jQuery (यह) .attr ('checked',! jQuery (यह) .attr ('checked'));}); }   

पहले क्लिक पर, सभी चेकबॉक्सेस की जांच हो जाती है, इसे फिर से क्लिक करें, और उन्हें अनचेक किया जाता है।

दूसरा क्लिक, बक्से में कोई चेकमार्क प्रदर्शित नहीं होता, हालांकि,

मैं चेकमार्क को कैसे दिखा सकता हूं?

= "post-text" itemprop = "text">

इस स्थिति में, .prop () का उपयोग .attr () के स्थान पर किया जाएगा। लेकिन ईमानदारी से, यह या तो बेहतर नहीं होगा:

  this.checked =! This.checked;    

Comments

Popular posts from this blog

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

Installing croogo for cakephp -