Posted February 12, 2016
Filed Under: blog
Alright, so we all know (or should know) about prefixing href attributes with the ‘mailto:email@example.com’ to get the link to open the mail client on the user’s computer and send an email. This is groovy. Did you know the href attribute accepts other prefixes, too? Like, if you’re targeting mobile users and want an easy way for them to call you:
<a href='tel:414-123-4567' rel='telephone'>414-123-4567</a>
^ That would do the trick. You can also prefix with ftp: and telnet: (to support FTP and telnet protocols) and some other interesting (yet not-so-applicable today) prefixes. Read about it on IETF’s site.