Help a newbie. There is a button on the page, it is created using a script from another service (widget to order a call). This button has lt-label and lt-online or lt-offline classes. It is created dynamically and placed in the body .
There is also a static fixed button.
Question: how can js hide a static button if dynamic has a class lt-offline ?
Tried so
$(document).ready(function() { if (document.getElementsByClassName) { var redTags = document.getElementsByClassName('lt-label'); if (redTags.is(".lt-offline")) { $("#lb-wrapper").css({ 'display': 'none' }); }; }; }); But it does not work because of the fact that here and just js and jquery. How do I do right?