When you click the below button, it checks whether the class 'myhasclass' is exist or not. If the class is exists, it gives true in the alert message. Otherwise, it gives false in the alert message box.
'myhasclass'
This is the jQuery Tutorial of check CSS class existence.
Go to Tutorialdeep Homepage