Forward the Phone Number
To add a script that forwards the user to a phone app with the number automatically entered:
-
Use a text editor or code editor for creating (or updating) the JavaScript file.
-
Add the following script:
$(document).ready(function () { for (const phoneLink of document.getElementsByClassName("link tel")) { phoneLink.href = `tel:${phoneLink.getAttribute('href')}` } });
-
Save your JavaScript file making sure it has a
.js
filename extension.