How to use WhatsApp on website
Nowadays, to contact any person or inquire about services, courses, etc., via WhatsApp is most popular because we can contact internationally, many websites use WhatsApp to easy contact. Here are the steps following to use WhatsApp on websites:
HTML CODE
<a href="https://wa.me/917838370333?text=" onclick="gtag('event', 'WhatsApp', {'event_action': 'whatsapp_chat', 'event_category': 'Chat', 'event_label': 'Chat_WhatsApp'});" target="_blank" class="whatsappicon"><i class="fab fa-whatsapp"></i> Chat on Whatsapp </a>
Here in this HTML code, there are some points you should keep in mind:
1. href: in href place, your mobile number, when you use your mobile number you should keep in mind one thing you don’t have to use space or any other special symbol in mobile digits like that (7838 37 0333, 7838-37-0333). If you do so then WhatsApp link will not work.
2. onclick event: here onclick event is used to make this WhatsApp link work on mobile. You should keep in mind don’t remove this onclick event. If you do so, then it will not work on mobile.