Answers for "jquery if selector exists"

0

jquery selector exists

if ($(selector).length ) {
    // Do something
}
Posted by: Guest on August-05-2021
-1

jQuery exists function

if ($("#myElementID").length){
   //I exist
}
Posted by: Guest on July-22-2019

Code answers related to "Javascript"

Browse Popular Code Answers by Language