It worked a year ago, but now it opens a new window/tab (which is the correct behavior), but it stays blank and does not open the URL specified.
I allowed popups in my Chrome setting but still the same result.
Pasting and executing the URL by hand works fine (like https://api.whatsapp.com/send?text=bla ).
<p>
<span class="tooltip"
><i class="fa fa-whatsapp"></i> <a
id="lblSuccess2"
href="javascript:sendWA()"
target="_blank"
><span class="tooltiptext" id="myTooltip2"
>Klik om te delen via WhatsApp</span
>WhatsApp</a
></span
>
</p>
function sendWA() {
var tekst = document.getElementById("txtVoorbeeldtekst").value;
var uriWA = "https://api.whatsapp.com/send?text=".concat(
encodeURIComponent(tekst)
);
window.open(uriWA, "_blank");
return false;
}