I was wanting to know if Android had a similar feature to the iPhone in that you can use an HTML A tag to send an SMS by setting the HREF
attribute to the phone number you want to send the message to and prefixing it with "SMS:", i.e. href="SMS:02313213"
I've had a look around and can't seem to find anything that suggests it is available on Android.
To include a link in any text message, just type or paste the full URL into your text. Most messaging platforms will automatically turn the URL into a link that allows contacts to click and access the linked page.
the sms:LINK service. sms:LINK enables sending large numbers of SMS messages to individuals or selected groups via the Internet (via an e-mail account). Just write and send the e-mail and customers will receive an SMS message to their mobile phones within seconds.
android.telephony.SmsManager. Manages SMS operations such as sending data, text, and pdu SMS messages. Get this object by calling the static method getDefault() . To create an instance of SmsManager associated with a specific subscription ID, call getSmsManagerForSubscriptionId(int) .
I found the following which may help you:
https://www.rfc-editor.org/rfc/rfc5724
You can check sub-section 2.5 or 2.6 of this RFC to give you some additional pointers on formulating a proper SMS URL.
Eg. using formal URI-spec as detailed in sub-section 2.2 of rfc5724:
<a href="sms:+19725551212?body=hello%20there">SMS Me</a>
Notice the 'escaped' character for the 'space' in the example above.
Hopefully the Android browser will permit you to generate XHTML forms based on this syntax. I believe they will (if I have some time over the next day, I shall give it a try on my Galaxy S).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With