Search code examples
javascriptfirefoxfirefox-addontel

Have a firefox extension recognise a tel: tag and hangle it?


I'm developing a click-to-dial tool, and would like to pass all tel: links in firefox to my extension, which will then run click to dial

so

<a href="tel:01223236103">Call this customer</a> 

should silently be passed to my extension to deal with and not ask the user which external application they wish to launch

This is primarily for Mac users although it should ideally be a cross-platform solution (so handled within the JavaScript rather than using any external applications)

Any suggestions where to look/what to Google?


Solution

  • I solved this by writing and registering my own protocol handler

    1. Mike's blog gives a helpful walkthrough

    2. Mozillazine explains what you're doing