I try to show the WhatsApp
Baloon Button after 3 seconds in AMP Page, but it's still failed. I try to debug within inspect
element in Chrome
but nothing errors found.
Here're the code:
CSS:
<style amp-custom>
.hide {
display: none;
}
</style>
HTML:
...
<script id="script1" type="text/plain" target="amp-script">
setTimeout(function(){
document.getElementById('wabox').classList.remove('hide');
}, 3000);
</script>
<a id="wabox" rel="nofollow"
href="https://api.whatsapp.com/send?phone=XXXXXX&text=Hi%2C%20I%20am%20Interested..."
class="wafloat hide" target="_blank">
<i class="fa fa-whatsapp my-float gacontact wafloatx">
<amp-img alt="Contact us"
width="64"
height="64"
src="img/wa-min.webp">
</amp-img>
</i>
</a>
...
any idea?
Thank You in advance...