I want to send a sms message with the message body like "where am I?" when I click "where am I?", it will take me to the google map website with my location. My question is that how can I add this hyperlink in the "where am I?" message text? Is there any example that I can study?
The short answer is, adding hyperlinks into SMS text messages isn't possible. Hyperlinks can only be used in emails and on your business website.
On your Android tablet or phoneat the top of your screen, tap Home, and then tap Insert. Tap Link. Enter the text to display and the address of your link. Tap Insert.
SMSes are text-only, and they only allow 160 characters. What you are suggesting would include 'where am I?' in the 160 characters but also somehow include a very long web address.
The first thing you might want to do is make use of some sort of URL-shortening service. I don't have one that I can personally recommend but there are Django apps, among other things, and online services that you can hook into with an API (like bit.ly). That will get you a unique link to easily fit in the available characters of an SMS.
Most smart phones will parse a link and make it 'clickable', even if it is in an SMS. So, for example, you could make the text read:
Where am I? www.linkgoesh.ere/somehash
The user should be able to click on the link and visit your website. It's not as elegant as what you're suggesting, but SMS is a (necessarily) limited format.
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