Using JQUERY to select all and deselect all is not as cumbersome as js and supports more browsers. Copy code The code is as follows: