jQuery - Check if element exist with .length

0 votes
266 views
added Nov 17, 2018 in jQuery by LC Marshal Captain (25,790 points)
 var ifframe = $('.sto-ads #div-gpt-ad-1542355261776-0_ad_container');
  if($(ifframe).length){
      alert('hey');
 }

 

lazacode.org - Malaysia's programming knowledge sharing platform, where everyone can share their finding as reference to others.
...