Page 1 of 1

sms: location not working on all devices

Posted: Thu Jan 17, 2013 8:10 pm
by SteveLacy

I'm using the native call to location sms:xxxxxxxxxx and it doesn't work consistently. On the iPad, it seems to work, although it doesn't work on the iPhone (it launches the text message tool, but it doesn't pre-populate the phone number).

Is there anything I can do to ensure it's working on all devices?

Here's the javascript...

var str=localStorage.getItem('callnum');
var str=str.replace("(","");
var str=str.replace(")","");
var str=str.replace("-","");
var str=str.replace(" ","");

chyea ='sms:' + str;
window.location.href = chyea;


sms: location not working on all devices

Posted: Thu Jan 17, 2013 8:12 pm
by maxkatz

The sms: protocol is supported differently on on various devices/mobile OSs. There are might be workarounds for a particular platform on the Internet.